|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectweka.classifiers.Classifier
weka.classifiers.trees.Id3
Class implementing an Id3 decision tree classifier. For more information, see
R. Quinlan (1986). Induction of decision trees. Machine Learning. Vol.1, No.1, pp. 81-106.
Constructor Summary | |
Id3()
|
Method Summary | |
void |
buildClassifier(Instances data)
Builds Id3 decision tree classifier. |
double |
classifyInstance(Instance instance)
Classifies a given test instance using the decision tree. |
double[] |
distributionForInstance(Instance instance)
Computes class distribution for instance using decision tree. |
java.lang.String |
globalInfo()
Returns a string describing the classifier. |
static void |
main(java.lang.String[] args)
Main method. |
java.lang.String |
toString()
Prints the decision tree using the private toString method from below. |
Methods inherited from class weka.classifiers.Classifier |
debugTipText, forName, getDebug, getOptions, listOptions, makeCopies, setDebug, setOptions |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Id3()
Method Detail |
public java.lang.String globalInfo()
public void buildClassifier(Instances data) throws java.lang.Exception
buildClassifier
in class Classifier
data
- the training data
java.lang.Exception
- if classifier can't be built successfullypublic double classifyInstance(Instance instance) throws NoSupportForMissingValuesException
classifyInstance
in class Classifier
instance
- the instance to be classified
NoSupportForMissingValuesException
public double[] distributionForInstance(Instance instance) throws NoSupportForMissingValuesException
distributionForInstance
in class Classifier
instance
- the instance for which distribution is to be computed
NoSupportForMissingValuesException
public java.lang.String toString()
public static void main(java.lang.String[] args)
args
- the options for the classifier
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |