14 - Association Rules Flashcards
What is the form of association rules?
If antecedent, then consequent
What are the two key measures associated with an association rule?
- Support
- Confidence
What does support represent in an association rule?
The proportion of transactions that contain both A and B
Define confidence in the context of association rules.
The percentage of transactions containing A that also contain B
What is the curse of dimensionality?
The exponential growth of possible association rules with the number of attributes
What is the a priori algorithm used for?
Mining association rules more efficiently by reducing the search space
What is an example of a trivial rule that is excluded from association rules?
If beans and squash, then beans
How is lift defined in association rules?
The ratio of the confidence of the rule to the prior probability of the consequent
True or False: Lift indicates how much more likely the consequent is given the antecedent compared to the general population.
True
What is the significance of the lift value greater than 1?
It indicates that the antecedent increases the likelihood of the consequent
Fill in the blank: The support for an association rule A ⇒ B is calculated as _______.
number of transactions containing both A and B / total number of transactions
What are the three measures of goodness for an association rule?
- Support
- Confidence
- Lift
What is the minimum support threshold set for rule mining in the example?
0.01 (1%)
What does the term ‘antecedent’ refer to in an association rule?
The item or set of items that imply the consequent
What is the minimum confidence threshold set for rule mining in the example?
0.4 (40%)
What does ‘max number of antecedents’ specify in the context of mining rules?
The maximum number of items that can be in the antecedent
How do you convert a variable to an ordinal factor in R?
Use the ordered() function on as.factor()
What is the purpose of the apriori() function in R?
To generate association rules based on specified parameters
What command is used to inspect the top rules sorted by lift in R?
inspect(head(all.rules, by = ‘lift’, n = 10))
What should be done to rules containing Churn in the antecedent?
Delete those rules
What is the first step in mining association rules using R?
Read in the data set and subset the desired variables
What does the term ‘mutually exclusive’ refer to in the context of association rules?
Antecedent A and consequent B cannot contain the same items
How is the lift interpreted for the rule ‘If buy diapers, then buy beer’ with a lift value of 2.5?
Customers who buy diapers are 2.5 times as likely to buy beer as the general population
What do zeros and ones represent in the context of antecedents?
Zero means the antecedent did not meet the condition and one means that it did.