org.knime.base.node.mine.subgroupminer.apriori
Class TIDApriori

java.lang.Object
  extended by org.knime.base.node.mine.subgroupminer.apriori.TIDApriori
All Implemented Interfaces:
AprioriAlgorithm

public class TIDApriori
extends Object
implements AprioriAlgorithm

The TIDApriori algorithm is actually an Eclat implementation, since it realizes a depth first search. First of all, the frequent items are determined and stored with the transaction ids. Then, in a depth-first-search manner, the items are combined to larger itemsets by taking the next item from the frequent ones and join their transaction ids until the support is less than the minimum support.

Author:
Fabian Dill, University of Konstanz

Constructor Summary
TIDApriori()
           
 
Method Summary
 void findFrequentItems(List<BitVectorValue> transactions, ExecutionMonitor exec)
          Identify those items which occur in a sufficient, that is the minimum support, number of transactions and stores them with the ids of the transactions they appear in.
 void findFrequentItemSets(List<BitVectorValue> transactions, double minSupport, int maxDepth, FrequentItemSet.Type type, ExecutionMonitor exec)
          This is the method to start with when mining for frequent itemsets.
 List<AssociationRule> getAssociationRules(double confidence)
          Returns the association rules generated from the found frequent itemsets with the passed minimal confidence.
 List<FrequentItemSet> getFrequentItemSets(FrequentItemSet.Type type)
          Returns the found frequent itemsets according to their type, which can either be FREE, CLOSED or MAXIMAL.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TIDApriori

public TIDApriori()
Method Detail

findFrequentItems

public void findFrequentItems(List<BitVectorValue> transactions,
                              ExecutionMonitor exec)
                       throws CanceledExecutionException
Identify those items which occur in a sufficient, that is the minimum support, number of transactions and stores them with the ids of the transactions they appear in. At the end the always frequent items, which occur in every transaction are filtered.

Parameters:
transactions - the database containing the transactions as BitSets
exec - the execution monitor
Throws:
CanceledExecutionException - if user cancels execution

findFrequentItemSets

public void findFrequentItemSets(List<BitVectorValue> transactions,
                                 double minSupport,
                                 int maxDepth,
                                 FrequentItemSet.Type type,
                                 ExecutionMonitor exec)
                          throws CanceledExecutionException
This is the method to start with when mining for frequent itemsets.

Specified by:
findFrequentItemSets in interface AprioriAlgorithm
Parameters:
transactions - a list of BitSets representing the bitvectors, thus, corresponding to the whole database
minSupport - the minimum support as an absolute value
maxDepth - the maximal length of an itemset
type - the desired type of the frequent itemsets
exec - the execution monitor
Throws:
CanceledExecutionException - if the execution was cancelled

getFrequentItemSets

public List<FrequentItemSet> getFrequentItemSets(FrequentItemSet.Type type)
Returns the found frequent itemsets according to their type, which can either be FREE, CLOSED or MAXIMAL.

Specified by:
getFrequentItemSets in interface AprioriAlgorithm
Parameters:
type - the desired type, either free, closed or maximal
Returns:
a list of the found frequent itemsets of the referring type

getAssociationRules

public List<AssociationRule> getAssociationRules(double confidence)
Returns the association rules generated from the found frequent itemsets with the passed minimal confidence.

Specified by:
getAssociationRules in interface AprioriAlgorithm
Parameters:
confidence - the desired minimal confidence of the rules
Returns:
a list of associaiton rules with the minimum confidence


Copyright, 2003 - 2010. All rights reserved.
University of Konstanz, Germany.
Chair for Bioinformatics and Information Mining, Prof. Dr. Michael R. Berthold.
You may not modify, publish, transmit, transfer or sell, reproduce, create derivative works from, distribute, perform, display, or in any way exploit any of the content, in whole or in part, except as otherwise expressly permitted in writing by the copyright owner or as specified in the license file distributed with this product.