ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost
Class PrePost
- java.lang.Object
-
- ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost
-
public class PrePost extends java.lang.ObjectJava implementation of the PrePost algorithm. This implementation was obtained by converting the original C++ code of Prepost by ZHIHONG DENG to Java. The code is copyright by Zhihong Deng.
-
-
Field Summary
Fields Modifier and Type Field and Description int[][]bfintbf_colintbf_currentSizeintbf_cursorintbf_sizeca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.PPCTreeNode[]headTableint[]headTableLenca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.Item[]itemint[]itemsetCountintminSupportintnlLenSumintnlNodeCountca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.NodeListTreeNodenlRootintnumOfFItemca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.PPCTreeNodeppcRootint[]resultintresultCountintresultLenint[]sameItems
-
Constructor Summary
Constructors Constructor and Description PrePost()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidprintStats()Print statistics about the latest execution of the algorithm to System.out.voidrunAlgorithm(java.lang.String filename, double minsup, java.lang.String output)Run the algorithmvoidtraverse(ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.NodeListTreeNode curNode, ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.NodeListTreeNode curRoot, int level, int sameCount)Recursively traverse the tree to find frequent itemsets
-
-
-
Field Detail
-
bf
public int[][] bf
-
bf_cursor
public int bf_cursor
-
bf_size
public int bf_size
-
bf_col
public int bf_col
-
bf_currentSize
public int bf_currentSize
-
numOfFItem
public int numOfFItem
-
minSupport
public int minSupport
-
item
public ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.Item[] item
-
result
public int[] result
-
resultLen
public int resultLen
-
resultCount
public int resultCount
-
nlLenSum
public int nlLenSum
-
ppcRoot
public ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.PPCTreeNode ppcRoot
-
nlRoot
public ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.NodeListTreeNode nlRoot
-
headTable
public ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.PPCTreeNode[] headTable
-
headTableLen
public int[] headTableLen
-
itemsetCount
public int[] itemsetCount
-
sameItems
public int[] sameItems
-
nlNodeCount
public int nlNodeCount
-
-
Method Detail
-
runAlgorithm
public void runAlgorithm(java.lang.String filename, double minsup, java.lang.String output) throws java.io.IOExceptionRun the algorithm- Parameters:
filename- the input file pathminsup- the minsup thresholdoutput- the output file path- Throws:
java.io.IOException- if error while reading/writting to file
-
traverse
public void traverse(ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.NodeListTreeNode curNode, ca.pfv.spmf.algorithms.frequentpatterns.fin_prepost.PrePost.NodeListTreeNode curRoot, int level, int sameCount) throws java.io.IOExceptionRecursively traverse the tree to find frequent itemsets- Parameters:
curNode-curRoot-level-sameCount-- Throws:
java.io.IOException- if error while writing itemsets to file
-
printStats
public void printStats()
Print statistics about the latest execution of the algorithm to System.out.
-
-
DMelt 3.0 © DataMelt by jWork.ORG