public class NBNodeAdaptive extends NBNode implements LearningNode, Serializable
m_weightSeenAtLastSplitEvalm_parentBranch, m_parentNode, m_theNodem_classDistribution| Constructor and Description |
|---|
NBNodeAdaptive(Instances header,
double nbWeightThreshold)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
double[] |
getDistribution(Instance inst,
Attribute classAtt)
Return a class probability distribution computed from the frequency counts
at this node
|
void |
updateNode(Instance inst)
Update the node with the supplied instance
|
getPossibleSplitsclassDistributionIsPure, graphTree, installNodeNums, isLeaf, leafForInstance, numEntriesInClassDistribution, toString, totalWeight, updateDistributionpublic NBNodeAdaptive(Instances header, double nbWeightThreshold) throws Exception
header - the structure of the instances we're training fromnbWeightThreshold - the weight mass to see before allowing naive Bayes
to predictException - if a problem occurspublic void updateNode(Instance inst) throws Exception
HNodeupdateNode in class NBNodeinst - the instance to update withException - if a problem occurspublic double[] getDistribution(Instance inst, Attribute classAtt) throws Exception
HNodegetDistribution in class NBNodeinst - the instance to get a prediction forclassAtt - the class attributeException - if a problem occursCopyright © 2016 University of Waikato, Hamilton, NZ. All Rights Reserved.