🎯 Objectives
The recommendation system is developed with several primary objectives:
- Analyze purchasing patterns from cosmetic product transaction data.
- Discover associations between products frequently bought together.
- Generate recommendation rules based on minimum support and confidence values. Compare the performance of Apriori and FP-Growth algorithms.
- Assist businesses in designing optimal product layouts for cross-selling.
- Provide visual insights through statistical dashboards and comparison charts.
📌 Workflow
The overall workflow consists of the following stages:
- Upload cosmetic transaction dataset (CSV).
- Validate and preview transaction records.
- Perform data preprocessing (cleaning, basket transformation, one-hot encoding, optional train-test split).
- Configure minimum support and confidence values.
- Execute the Apriori algorithm.
- Execute the FP-Growth algorithm.
- Generate frequent itemsets and association rules.
- Compare algorithm performance through charts and statistical summaries.
- Produce product placement recommendations.
- Draw conclusions and identify the most suitable algorithm based on the experimental results.
⚙️ Algorithms Implemented
1. Apriori Algorithm
The Apriori algorithm identifies frequent itemsets by generating candidate combinations iteratively.
Characteristics
- Uses iterative candidate generation.
- Prunes infrequent itemsets based on minimum support.
- Generates association rules using confidence values.
- Easy to understand and implement.
- Computational cost increases significantly as the dataset grows.
Advantages
- Simple methodology.
- Well-established algorithm.
- Suitable for small and medium-sized datasets.
Limitations
- Generates many candidate itemsets.
- Multiple database scans.
- Less efficient for large datasets.
2. FP-Growth Algorithm
FP-Growth (Frequent Pattern Growth) improves efficiency by avoiding repeated candidate generation.
Instead of creating numerous candidate combinations, FP-Growth compresses the transaction database into a compact Frequent Pattern Tree (FP-Tree).
Characteristics
- Uses FP-Tree structure.
- Requires fewer database scans.
- Eliminates repetitive candidate generation.
- Performs efficiently on large datasets.
Advantages
- Faster execution.
- Lower memory consumption.
- Better scalability.
- Suitable for large transaction datasets.
Limitations
- FP-Tree construction is more complex.
- More difficult to understand compared to Apriori.