Database Reference
In-Depth Information
matches the total number of 59 frequent 1-itemsets, 61 frequent 2-itemsets, and 2
frequent 3-itemsets.
itemsets <- apriori(Groceries, parameter=list(minlen=1,
support=0.02,
target="frequent itemsets"))
parameter specification:
confidence minval smax arem aval originalSupport support
minlen
0.8 0.1 1 none FALSE TRUE 0.02 1
maxlen target ext
10 frequent itemsets FALSE
algorithmic control:
filter tree heap memopt load sort verbose
0.1 TRUE TRUE FALSE TRUE 2 TRUE
apriori - find association rules with the apriori algorithm
version 4.21 (2004.05.09) (c) 1996-2004 Christian Borgelt
set item appearances …[0 item(s)] done [0.00s].
set transactions …[169 item(s), 9835 transaction(s)] done
[0.00s].
sorting and recoding items … [59 item(s)] done [0.00s].
creating transaction tree … done [0.00s].
checking subsets of size 1 2 3 done [0.00s].
writing … [122 set(s)] done [0.00s].
creating S4 object … done [0.00s].
Note that the results are assessed based on the specific business context of the
exercise using the specific dataset. If the dataset changes or a different minimum
support threshold is chosen, the Apriori algorithm must run each iteration again to
retrieve the updated frequent itemsets.
5.5.3 Rule Generation and Visualization
The apriori() function can also be used to generate rules. Assume that the
minimum support threshold is now set to a lower value 0.001, and the minimum
confidence threshold is set to 0.6. A lower minimum support threshold allows
more rules to show up. The following code creates 2,918 rules from all the
transactions in the Groceries dataset that satisfy both the minimum support and
the minimum confidence.
Search WWH ::




Custom Search