I am using the arules package in R to create association rules. The rules that are created always have just one term on the RHS (consequent). Does anyone know if there is a way to get more than 1 term on the RHS?
Asked
Active
Viewed 1,015 times
1 Answers
1
The only way to achieve this using ARULES is to re-code those pairings (the RHS consequents) as a single item. For example, if you want to know if A leads to B&C, you could define an item D as being "both B & C".
In the documentation of the ARULES package, it is specifically mentioned that Apriori will only create rules with a single item in the RHS ("consequent") [see page 10, http://cran.r-project.org/web/packages/arules/arules.pdf]
Depending on your data, this may or may not be a reasonable workaround. If you have some consequent pairs that you're interested in, you can try it, but creating an exhaustive list of possible pairings might be prohibitively time consuming depending on the number of pairings you're interested in.

user2432675
- 715
- 1
- 6
- 14