NEW
A classic algorithm for discovering frequent itemsets and association rules in transactional datasets.
DESCRIPTION
Apriori iteratively generates candidate itemsets and prunes them using the downward closure property: all subsets of a frequent itemset must be frequent. It computes support and derives association rules with confidence and lift measures. The algorithm is used in market basket analysis and recommendation pre-processing. It is simple but can be costly due to candidate explosion and database scans. Alternatives like FP-Growth improve efficiency via compact data structures. Parameter tuning of minimum support and confidence controls result size and quality. Careful post-processing prevents spurious rules.
ALTERNATIVE DEFINITIONS
Wikipedia
The Apriori algorithm is an algorithm for frequent item set mining and association rule learning over transactional databases.
States mining of frequent itemsets and rule learning.
mlxtend
Apriori is a classic algorithm for frequent itemset mining that uses candidate generation to find itemsets that satisfy a minimum support threshold.
Highlights candidate generation and support threshold.
RELATED TERMS
Association Rules Frequent Itemset Mining Support Confidence Lift Market Basket Analysis Unsupervised Learning Pattern Mining Data Mining
COMPETING TERMS
RELATIONS
- Broader: Algorithm Data Mining Unsupervised Learning
KNOWLEDGE AREAS
TARGET AUDIENCE
Data Scientist Data Analyst AI Engineer
EXTERNAL SOURCES
- Wikipedia - Apriori algorithm
- UMass Boston - Lecture notes on Apriori
- mlxtend - Python implementation of Apriori
TOP QUESTIONS
What is the core principle behind the Apriori Algorithm?
The downward closure property: if an itemset is frequent, all its subsets are also frequent.
Category: Overview
Why can Apriori be slow on large datasets?
Candidate generation and multiple database scans can cause high computational overhead and memory use.
Category: Mistakes
How do support and confidence relate in Apriori?
Support filters frequent itemsets; confidence assesses rule reliability from those itemsets.
Category: Requirements
When is FP-Growth preferred over Apriori?
When datasets are large or dense; FP-Growth avoids candidate generation using an FP-tree.
Category: Alternatives
What are common pitfalls using Apriori?
Setting thresholds too low produces spurious rules; too high misses meaningful patterns.
Category: Mistakes
How can lift help evaluate Apriori rules?
Lift reveals whether co-occurrence exceeds random expectation, highlighting impactful associations.
Category: Testing
Where is Apriori most useful?
Market basket analysis, cross-selling insights, and discovering co-purchase patterns.
Category: Example
How to start with Apriori on new data?
Profile transaction density, set reasonable support thresholds, and iterate with rule evaluation metrics.
Category: Management
Does Apriori support streaming data?
Classic Apriori is batch-oriented; incremental variants exist but are less common.
Category: Misunderstanding