com.rapidminer.operator.learner.bayes
Class DistributionModel
java.lang.Object
com.rapidminer.operator.AbstractIOObject
com.rapidminer.operator.ResultObjectAdapter
com.rapidminer.operator.AbstractModel
com.rapidminer.operator.learner.PredictionModel
com.rapidminer.operator.learner.bayes.DistributionModel
- All Implemented Interfaces:
- IOObject, Model, ResultObject, Saveable, Readable, Reportable, LoggingHandler, java.io.Serializable
- Direct Known Subclasses:
- KernelDistributionModel, SimpleDistributionModel
public abstract class DistributionModel
- extends PredictionModel
DistributionModel is a model for learners which estimate distributions
of attribute values from example sets like NaiveBayes.
Predictions are calculated as product of the conditional probabilities
for all attributes times the class probability.
The basic learning concept is to simply count occurances of classes
and attribute values. This means no propabilities are calculated during
the learning step. This is only done before output. Optionally, this
calculation can apply a Laplace correction which means in particular
that zero probabilities are avoided which would hide information
in distributions of other attributes.
- Author:
- Tobias Malbrecht
- See Also:
- Serialized Form
| Methods inherited from class com.rapidminer.operator.ResultObjectAdapter |
addAction, getActions, getVisualizationComponent, isSavable, log, logError, logNote, logWarning, save, toHTML, toResultString |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
DistributionModel
public DistributionModel(ExampleSet exampleSet)
getAttributeNames
public abstract java.lang.String[] getAttributeNames()
getNumberOfAttributes
public abstract int getNumberOfAttributes()
getLowerBound
public abstract double getLowerBound(int attributeIndex)
getUpperBound
public abstract double getUpperBound(int attributeIndex)
isDiscrete
public abstract boolean isDiscrete(int attributeIndex)
getClassIndices
public abstract java.util.Collection<java.lang.Integer> getClassIndices()
getNumberOfClasses
public abstract int getNumberOfClasses()
getClassName
public abstract java.lang.String getClassName(int index)
getDistribution
public abstract Distribution getDistribution(int classIndex,
int attributeIndex)
performPrediction
public abstract ExampleSet performPrediction(ExampleSet exampleSet,
Attribute predictedLabel)
- Description copied from class:
PredictionModel
- Subclasses should iterate through the given example set and set the
prediction for each example. The given predicted label attribute was
already be added to the example set and should be used to set the
predicted values.
- Specified by:
performPrediction in class PredictionModel
Copyright © 2001-2009 by Rapid-I