Learn R Programming

arules (version 1.7-8)

is.generator: Find Generator Itemsets

Description

Provides the generic function and the method `is.generator() for finding generator itemsets. Generators are part of concise representations for frequent itemsets. A generator in a set of itemsets is an itemset that has no subset with the same support (Liu et al, 2008). Note that the empty set is by definition a generator, but it is typically not stored in the itemsets in arules.

Usage

is.generator(x)

# S4 method for itemsets is.generator(x)

Value

a logical vector with the same length as x indicating for each element in x if it is a generator itemset.

Arguments

x

a set of itemsets.

Author

Michael Hahsler

References

Yves Bastide, Niolas Pasquier, Rafik Taouil, Gerd Stumme, Lotfi Lakhal (2000). Mining Minimal Non-redundant Association Rules Using Frequent Closed Itemsets. In International Conference on Computational Logic, Lecture Notes in Computer Science (LNCS 1861). pages 972--986. tools:::Rd_expr_doi("10.1007/3-540-44957-4_65")

Guimei Liu, Jinyan Li, Limsoon Wong (2008). A new concise representation of frequent itemsets using generators and a positive border. Knowledge and Information Systems 17(1):35-56. tools:::Rd_expr_doi("10.1007/s10115-007-0111-5")

See Also

Other postprocessing: is.closed(), is.maximal(), is.redundant(), is.significant(), is.superset()

Other associations functions: abbreviate(), associations-class, c(), duplicated(), extract, inspect(), is.closed(), is.maximal(), is.redundant(), is.significant(), is.superset(), itemsets-class, match(), rules-class, sample(), sets, size(), sort(), unique()

Examples

Run this code
# Example from Liu et al (2008)
trans_list <- list(
      t1 = c("a","b","c"),
      t2 = c("a","b", "c", "d"),
      t3 = c("a","d"),
      t4 = c("a","c")
      )

trans <- transactions(trans_list)
its <- apriori(trans, support = 1/4, target = "frequent itemsets")

is.generator(its)

Run the code above in your browser using DataLab