Apriori discovers frequent item sets by progressively extending combinations that meet a minimum support threshold. Its output can describe common records and support interpretable outlier scoring. section 3.2.4
Apply it to categorical or discretized tabular data by:
- Bin dates, times, and amounts when interpretability benefits from categorical values. section 3.2.4
- One-hot encode every feature, then represent zero and one values as Boolean indicators. section 3.2.4
- Run mlxtend.apriori with a chosen minimum support and optionally restrict item-set size. section 3.2.4
- Use the returned support and itemsets columns to compare how many frequent patterns each row contains. section 3.2.4
SpeedDating frequent item sets
With minimum support 0.3, the procedure finds common preferences such as ambitious scores [0–15] and shared-interests scores [0–15], plus their combination. These patterns contribute to FPOF scores: the most inlier row scores 0.0, while the most outlier row scores 1.0. section 3.2.4
Table 3.4 Staff expenses with binned values (view table figure)
| Row |
Staff ID |
Department |
Account |
Date of expense |
Date submitted |
Time submitted |
Amount |
|---|---|---|---|---|---|---|---|
| 1 |
9000483 |
Sales |
Meals |
2 |
2 |
9 |
2 |
| 2 |
9303332 |
Marketing |
Travel |
2 |
2 |
10 |
2 |
| 3 |
9847421 |
Engineering |
Meals |
2 |
2 |
10 |
3 |
| 4 |
9303332 |
Marketing |
Supplies |
2 |
2 |
11 |
3 |
| 5 |
9000483 |
Sales |
Meals |
2 |
2 |
11 |
2 |
| 6 |
9000483 |
Sales |
Meals |
2 |
2 |
12 |
2 |
Inspect the binned expense data used to turn dates, times, and amounts into interpretable categorical values before one-hot encoding. section 3.2.4

