void |
NaiveBayesClassifier.addClassLabel(String label) |
Add a class label.
|
void |
NaiveBayesClassifier.addFeature(String featureName) |
Adds a feature.
|
void |
NaiveBayesClassifier.addState(String featureName,
String stateLabel) |
Adds a new state of the given feature.
|
Double[] |
NaiveBayesClassifier.classify(Map<String,String> observations) |
The Naive Bayes classifiaction algorithm.
|
Double[] |
NaiveBayesClassifier.getConditionalProbabilities(String featureName,
String ofState) |
Returns the conditional probabilities of some feature state given all class labels.
|
String[] |
NaiveBayesClassifier.getStates(String featureName) |
Returns the states of a feature.
|
void |
NaiveBayesClassifier.removeFeature(String featureName) |
Remove a feature.
|
void |
NaiveBayesClassifier.removeLabel(String label) |
Removes the specified label.
|
void |
NaiveBayesClassifier.removeState(String featureName,
String stateLabel) |
Removes a state.
|
void |
NaiveBayesClassifier.setConditionalProbability(String featureName,
String ofState,
String givenLabel,
double conditionalProbability) |
Set the conditional probability of a state given a class label.
|
void |
NaiveBayesClassifier.setPriorProbability(String classLabel,
double priorProbability) |
Set the prior (default) probability of a class label.
|
void |
NaiveBayesClassifier.validate() |
Examines the consistency of prior and conditional probabilities and
throws an exception if inconsistent.
|