Question: Exercise 1 1 : Your task. ( basket _ rules _ test: 4 points ) . Your final task in this notebook is to mine
Exercise : Your task. basketrulestest: points Your final task in this notebook is to mine this dataset for pairwise association rules. In particular, your code should produce no pun intended! a final dictionary, basketrules, that meet these conditions read carefully!:
The keys are pairs ab
where a
and b
are item names as strings
The values are the corresponding confidence scores, confab
Only include rules ab
where item a
occurs at least MINCOUNT times and confab
is at least THRESHOLD.
Pay particular attention to Condition : not only do you have to filter by a confidence threshold, but you must exclude rules ab
where the item a
does not appear "often enough." There is a code cell below that defines values of MINCOUNT and THRESHOLD, but your code should work even if we decide to change those values later on
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
