Laia Mayol
2013-May-21 11:42 UTC
[R] Arules: getting rules with only one item in the left-hand side
Hello, I am using the package arules to generate association rules. I would like to restrict the rules so that in the left-hand side there's only one particular element, let's call it "potatoe". If I do this: rules <- apriori(dtm.mat, parameter = list(sup = 0.4, conf 0.9,target="rules"), appearance = list(lhs = c("potatoe"))) I get "potatoe" on the lhs, but also all other kinds of things. How can I force that the rules contain only one element? The parameter maxlen don't do what I want, because, as far as I can see, I cannot specify the maxlen to apply to the elements on the left. Thanks! Laia
Maybe Matching Threads
- how to change number of itemes appeare in right-hand-side of the rule with apriori in R(arules)?
- arules: rules are built on item ordering in the dataframe, rather than
- arules "killed"
- arules package question- apriori/S4 object export question
- arules package apriori() fn error message XXXX