Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

is.significant

Find Significant Rules


Description

Provides the generic functions and the S4 method is.significant to find significant associations and an implementation for rules.

Usage

is.significant(x, transactions, method = "fisher", 
  alpha = 0.01, adjust = "bonferroni")

Arguments

x

a set of rules.

transactions

set of transactions used to mine the rules.

method

test to use. Options are "fisher", "chisq". Note that the contingency table is likely to have cells with low expected values and that thus Fisher's Exact Test might be more appropriate than the chi-squared test.

alpha

required significance level.

adjust

method to adjust for multiple comparisons. Options are "none", "bonferroni", "holm", "fdr", etc. (see p.adjust)

Details

The implementation for association rules uses Fisher's exact test with correction for multiple comparisons to test the null hypothesis that the LHS and the RHS of the rule are independent. Significant rules have a p-value less then the specified significance level alpha (the null hypothesis of independence is rejected.).

Value

returns a logical vector indicating which rules are significant.

Author(s)

Michael Hahsler

References

Hahsler, Michael and Kurt Hornik (2007). New probabilistic interest measures for association rules. Intelligent Data Analysis, 11(5):437–455.

See Also

Examples

data("Income")
rules <- apriori(Income, parameter = list(support = 0.5))
is.significant(rules, Income)

inspect(rules[is.significant(rules, Income)])

arules

Mining Association Rules and Frequent Itemsets

v1.6-7
GPL-3
Authors
Michael Hahsler [aut, cre, cph], Christian Buchta [aut, cph], Bettina Gruen [aut, cph], Kurt Hornik [aut, cph], Ian Johnson [ctb, cph], Christian Borgelt [ctb, cph]
Initial release
2021-03-12

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.