# Definition

An association rule takes the form *'**IF** X **THEN** Y '*, which means that knowing a condition *X* is satisfied, that rule could be used to lead to *Y*. 

More concretely, the rule can also be interpreted as '*IF X is purchased, THEN Y is likely to be purchased too '*.

- It is defined as an **implication between a condition X and a condition Y** and is **noted : X => Y ** (read "*X implies Y* ").
- **X is called the antecedent or left-hand-side of the rule**.
- **Y is called the consequent or right-hand-side of the rule**.


# Regarding our case study

Here are 3 examples of rules we could get as Market Basket analysis outputs:


## Purchasing tomato and bacon implies purchasing garlic : 
![rule_example_1.png](XugXXZ3pC6W3)


## Purchasing mushroom implies purchasing onion : 
![rule_example_2.png](kIVDePk1Ug3L)


## Purchasing pepper implies purchasing tortilla and garlic : 
![rule_example_3.png](5xbV65x7t1um)

> All emojis designed by [OpenMoji](https://openmoji.org/) – the open-source emoji and icon project. License: [CC BY-SA 4.0](https://creativecommons.org/licenses/by-sa/4.0/#).