ca.pfv.spmf.algorithms.classifiers.decisiontree.id3
Class AlgoID3
- java.lang.Object
-
- ca.pfv.spmf.algorithms.classifiers.decisiontree.id3.AlgoID3
-
public class AlgoID3 extends java.lang.ObjectThis is an implementation of the ID3 algorithm for creating a decision tree.
ID3 is a very popular algorithms described in many artificial intelligence and data mining textbooks.
-
-
Constructor Summary
Constructors Constructor and Description AlgoID3()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidprintStatistics()Print statistics about the execution of this algorithmDecisionTreerunAlgorithm(java.lang.String input, java.lang.String targetAttribute, java.lang.String separator)Create a decision tree from a set of training instances.
-
-
-
Method Detail
-
runAlgorithm
public DecisionTree runAlgorithm(java.lang.String input, java.lang.String targetAttribute, java.lang.String separator) throws java.io.IOException
Create a decision tree from a set of training instances.- Parameters:
input- path to an input file containing training instancestargetAttribute- the target attribute (that will be used for classification)separator- the separator in the input file (e.g. space).- Returns:
- a decision tree
- Throws:
java.io.IOException- exception if error reading the file
-
printStatistics
public void printStatistics()
Print statistics about the execution of this algorithm
-
-
DMelt 3.0 © DataMelt by jWork.ORG