is.significant | R Documentation |
Provides the generic functions is.significant()
and the method to
find significant rules.
is.significant(
x,
transactions,
method = "fisher",
alpha = 0.01,
adjust = "bonferroni"
)
## S4 method for signature 'rules'
is.significant(
x,
transactions,
method = "fisher",
alpha = 0.01,
adjust = "bonferroni"
)
x |
a set of rules. |
transactions |
set of transactions used to mine the rules. |
method |
test to use. Options are |
alpha |
required significance level. |
adjust |
method to adjust for multiple comparisons. Options are
|
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). See Hahsler and Hornik (2007) for details.
returns a logical vector indicating which rules are significant.
Michael Hahsler
Hahsler, Michael and Kurt Hornik (2007). New probabilistic interest measures for association rules. Intelligent Data Analysis, 11(5):437–455. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.3233/IDA-2007-11502")}
stats::p.adjust()
Other interest measures:
confint()
,
coverage()
,
interestMeasure()
,
is.redundant()
,
support()
Other postprocessing:
is.closed()
,
is.generator()
,
is.maximal()
,
is.redundant()
,
is.superset()
Other associations functions:
abbreviate()
,
associations-class
,
c()
,
duplicated()
,
extract
,
inspect()
,
is.closed()
,
is.generator()
,
is.maximal()
,
is.redundant()
,
is.superset()
,
itemsets-class
,
match()
,
rules-class
,
sample()
,
sets
,
size()
,
sort()
,
unique()
data("Income")
rules <- apriori(Income, parameter = list(support = 0.5))
is.significant(rules, Income)
inspect(rules[is.significant(rules, Income)])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.