0

This is how the data is stored in the file given. There are 8 attributes given. I need association rule mining done using Apriori Algorithm in WEKA.

Such as, if item 1 & item 2 are bought --> item 4 is also bought or something reasonable as that.

This is how the data is stored in the file given. There are 8 attributes given.

What I tried:

Converting the file into .arff format and loading into weka. Turning all attributes in Nominal and running the algorithm Apriori. But the rules generated are very weird.

This is how the result comes. It has no proper information. No rules like what i want, which actually define what a user will buy with what or anything.

i.e. the rules generated here are of no information to me, there is no relation/rules given as to which item will be bought with what.

This is how the result comes. It has no proper information. No rules, which actually define what a user will buy with what or anything.

How should I preprocess this data to format it well or if am making any other mistake would be really appreciated.

  • Please provide a [mcve] in your question rather than screenshots. – TylerH Nov 08 '17 at 16:57
  • Am sorry for the problems in question, its my first time and am in a hurry right now. If you need additional info, please ask. I appreciate the time you are giving. :) –  Nov 08 '17 at 17:10
  • I'm not sure if this really counts as a programming question but you're correct that you need to reformat the data if you want to find which items are bought together. At the moment you have a separate instance for each invoice line; what you want is one instance for each invoice and a separate column for each item type containing the number of that item bought on that order. I don't know an easy way to do this directly in Weka but for example you could achieve it in KNIME using a GroupBy node, and KNIME both has its own association rule methods and includes the methods from Weka. – nekomatic Nov 10 '17 at 12:21
  • Thank you @nekomatic for taking the time to comment. I guess that's the only way to go, I thought there might be something I might have overlooked in Weka, which might have helped in transformation. –  Nov 14 '17 at 11:44

0 Answers0