In this chapter, you’ll convert transactional datasets to a basket format, ready for analysis using the Apriori algorithm. You’ll then be introduced to the three main metrics for market basket analysis: support, confidence, and lift, before getting hands-on with the Apriori algorithm to extract rules from a transactional dataset. Lastly, You explore how the arules package is used for market basket analysis to retrieve basket rules and to help you find the most informative and relevant rules.