Class AlgoRULEGROWTH
- java.lang.Object
-
- org.processmining.logfiltering.algorithms.SPMF.RuleGrowth.AlgoRULEGROWTH
-
public class AlgoRULEGROWTH extends java.lang.ObjectThis is the original implementation of the RULEGROWTH algorithm for mining sequential rules common to several sequences where antecedent and consequent are unordered itemsets. The RuleGrowth algorithm is described in this paper:
Fournier-Viger, P., Nkambou, R. & Tseng, V. S. (2011). RuleGrowth: Mining Sequential Rules Common to Several Sequences by Pattern-Growth. Proceedings of the 26th Symposium on Applied Computing (ACM SAC 2011). ACM Press, pp. 954-959.
The main method of this algorithm is "runAlgorithm". It output the result to a file.- Author:
- Philippe Fournier-Viger
- See Also:
Occurence,Sequence,SequenceDatabase
-
-
Constructor Summary
Constructors Constructor Description AlgoRULEGROWTH()Default constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<java.util.Set<java.lang.Integer>>AntecedenceTraces()java.util.List<java.util.Set<java.lang.Integer>>FittedTraces()java.lang.String[]inputRules()java.lang.String[]outputRules()voidprintStats()Print statistics about the last algorithm execution to System.out.voidrunAlgorithm(double minSupport, double minConfidence, SequenceDatabase sequencedatabase)The main method to run the algorithmvoidrunAlgorithm(SequenceDatabase ruleSequencesDatabase, int relativeMinsup, double minConfidence)The main method to run the algorithmvoidsetMaxAntecedentSize(int maxAntecedentSize)Set the number of items that a rule antecedent should contain (optional).voidsetMaxConsequentSize(int maxConsequentSize)Set the number of items that a rule consequent should contain (optional).
-
-
-
Method Detail
-
runAlgorithm
public void runAlgorithm(double minSupport, double minConfidence, SequenceDatabase sequencedatabase) throws java.io.IOExceptionThe main method to run the algorithm- Parameters:
minSupport- : the minimum support (percentage as a double value)minConfidence- : the minimum confidence thresholdinput- : an input file path of a sequence databaseoutput- : a file path for writing the output file containing the seq. rules.- Throws:
java.io.IOException- if error reading/writing files
-
runAlgorithm
public void runAlgorithm(SequenceDatabase ruleSequencesDatabase, int relativeMinsup, double minConfidence) throws java.io.IOException
The main method to run the algorithm- Parameters:
relativeMinsup- : the minimum support as an integer value (a relative minimum support)minConfidence- : the minimum confidence thresholdinput- : an input file path of a sequence databaseoutput- : a file path for writing the output file containing the seq. rules.- Throws:
java.io.IOException- if error reading/writing files
-
inputRules
public java.lang.String[] inputRules()
-
outputRules
public java.lang.String[] outputRules()
-
FittedTraces
public java.util.List<java.util.Set<java.lang.Integer>> FittedTraces()
-
AntecedenceTraces
public java.util.List<java.util.Set<java.lang.Integer>> AntecedenceTraces()
-
setMaxAntecedentSize
public void setMaxAntecedentSize(int maxAntecedentSize)
Set the number of items that a rule antecedent should contain (optional).- Parameters:
maxAntecedentSize- the maximum number of items
-
setMaxConsequentSize
public void setMaxConsequentSize(int maxConsequentSize)
Set the number of items that a rule consequent should contain (optional).- Parameters:
maxConsequentSize- the maximum number of items
-
printStats
public void printStats()
Print statistics about the last algorithm execution to System.out.
-
-