org.apache.mahout.fpm.pfpgrowth.fpgrowth2
Class FPGrowthIds
java.lang.Object
org.apache.mahout.fpm.pfpgrowth.fpgrowth2.FPGrowthIds
public final class FPGrowthIds
- extends Object
Implementation of PFGrowth Algorithm
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
generateTopKFrequentPatterns
public static void generateTopKFrequentPatterns(Iterator<Pair<IntArrayList,Long>> transactionStream,
LongArrayList attributeFrequency,
long minSupport,
int k,
IntArrayList returnableFeatures,
org.apache.hadoop.mapred.OutputCollector<Integer,List<Pair<List<Integer>,Long>>> output)
throws IOException
- Generate Top K Frequent Patterns for every feature in returnableFeatures
given a stream of transactions and the minimum support
- Parameters:
transactionStream - Iterator of transactionattributeFrequency - list of frequent features and their support valueminSupport - minimum support of the transactionsk - Number of top frequent patterns to keepreturnableFeatures - set of features for which the frequent patterns are mined. If the
set is empty or null, then top K patterns for every frequent item (an item
whose support> minSupport) is generatedoutput - The output collector to which the the generated patterns are
written
- Throws:
IOException
Copyright © 2008–2014 The Apache Software Foundation. All rights reserved.