Package weka.classifiers.trees.j48
Class NBTreeClassifierTree
java.lang.Object
weka.classifiers.trees.j48.ClassifierTree
weka.classifiers.trees.j48.NBTreeClassifierTree
- All Implemented Interfaces:
Serializable,CapabilitiesHandler,Drawable,RevisionHandler
Class for handling a naive bayes tree structure used for classification.
- Version:
- $Revision: 14534 $
- Author:
- Mark Hall (mhall@cs.waikato.ac.nz)
- See Also:
-
Field Summary
Fields inherited from interface weka.core.Drawable
BayesNet, Newick, NOT_DRAWABLE, TREE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidbuildClassifier(Instances data) Method for building a naive bayes classifier treeReturns the revision string.graph()Returns graph describing the tree.Print the models at the leavestoString()Prints tree structure.Methods inherited from class weka.classifiers.trees.j48.ClassifierTree
assignIDs, buildTree, buildTree, classifyInstance, cleanup, distributionForInstance, getCapabilities, getLocalModel, getMembershipValues, getSons, getTrainingData, graphType, isLeaf, numLeaves, numNodes, prefix, toSource
-
Constructor Details
-
NBTreeClassifierTree
-
-
Method Details
-
buildClassifier
Method for building a naive bayes classifier tree- Overrides:
buildClassifierin classClassifierTree- Parameters:
data- the data to build the tree from- Throws:
Exception- if something goes wrong
-
printLeafModels
Print the models at the leaves- Returns:
- textual description of the leaf models
-
toString
Prints tree structure.- Overrides:
toStringin classClassifierTree- Returns:
- the tree structure
-
graph
Returns graph describing the tree.- Specified by:
graphin interfaceDrawable- Overrides:
graphin classClassifierTree- Returns:
- the tree as graph
- Throws:
Exception- if something goes wrong
-
getRevision
Returns the revision string.- Specified by:
getRevisionin interfaceRevisionHandler- Overrides:
getRevisionin classClassifierTree- Returns:
- the revision
-