Classification using frequent patterns

There are two types of classification using frequent patterns:

  • Associative classification model as well as association rules, which are generated from frequent patterns and used for classifications
  • Discriminative frequent pattern-based classification

The associative classification

The generic association classification algorithm is defined here. The input parameters for the kNN algorithm are as follows:

  • D, which is a set of training objects
  • F, which is the itemset
  • MIN_SUP, which is the minimal support
  • MIN_CONF, which is the minimal confidence

The output of the algorithm is a rule-based classifier and is shown as follows:

The associative classification

Two popular algorithms are illustrated in the successive sections, one is Classification Based on Association (CBA), and the other is Classification Based on Multiple Association Rules (CMAR).

CBA

Here is the pseudocode for CBA:

CBA

Discriminative frequent pattern-based classification

Here is the pseudocode for discriminative frequent pattern-based classification:

Discriminative frequent pattern-based classification

The R implementation

Please look up the R codes files ch_04_associative_classification.R, ch_04_cba.R, and ch_04_frequent_pattern_based_classification.R from the bundle of R codes for the previously mentioned algorithms. The codes can be tested with the following commands:

> source("ch_04_associative_classification.R")
> source("ch_04_cba.R")
> source("ch_04_frequent_pattern_based_classification.R")

Text classification using sentential frequent itemsets

One application of CBA is text classification. The key here is to build a matrix with a document or text term and labels. With the matrix built, any classification algorithm can be applied to it. One example of document matrix is illustrated here. The term might include a character, word, phrase, and concept and so on.

Text classification using sentential frequent itemsets
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.139.97.40