3
$\begingroup$

actually I have to extract from my data the frequent pattern in R.

The first algorithm I have used is apriori but reading some articles I have seen that also eclat is available in the same package.

My questions are: - Can we suppose that both algorithm retrive the same information ? For example when I set the same min support - Why if I use eclat the items are listed with the support information ?

The R codes I use are the following ones:

for APRIORI:

v_rules <- apriori(v_sold_tran, parameter = list(minlen=2,maxlen = 5,sup = 0.005, conf = 0.01, target="rules"))    

for ECLAT:

itemsets <- eclat(v_sold_tran,parameter = list(supp = 0.005, maxlen = 5))
$\endgroup$
2
$\begingroup$

For the same minimum support, both algorithms must give the same result, or there is an error in their implementation. There is only one correct output.

I would assume that Apriori works better for many many many transactions, but fewer items, whereas Eclat probably works better for fewer transactions with more items. But that is just my guess. You'll have to figure this out yourself.

$\endgroup$
1
$\begingroup$

ECLAT improves Apriori in the step of Extracting frequent itemsets. As you know Apriori has to scan the Database multiple times, but with ECLAT there is no need to scan the database for countig the support for k-itemsets (k>=1). In R, apriori() could have as an output the frequent itemsets or association rules. Althought eclat() has as an output just the frequent itemsets. You have after that use the command ruleInduction() to extract rules from those itemsets.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.