ObservationType
- Observations from the ConditionalType that are used to estimate the
parameters of the distribution.BeliefType
- Type of Distribution that represents uncertainty in the parameters.ParameterType
- Type of parameter estimated by this algorithm, which is used to
parameterize the conditional distribution.ConditionalType
- Type of conditional distribution that generates observations for this
relationship.public abstract class AbstractConjugatePriorBayesianEstimator<ObservationType,ParameterType,ConditionalType extends ClosedFormDistribution<ObservationType>,BeliefType extends ClosedFormDistribution<ParameterType>> extends AbstractBatchAndIncrementalLearner<ObservationType,BeliefType> implements ConjugatePriorBayesianEstimator<ObservationType,ParameterType,ConditionalType,BeliefType>
Modifier and Type | Field and Description |
---|---|
protected BayesianParameter<ParameterType,ConditionalType,BeliefType> |
parameter
Bayesian hyperparameter relationship between the conditional
distribution and the conjugate prior distribution.
|
Constructor and Description |
---|
AbstractConjugatePriorBayesianEstimator(BayesianParameter<ParameterType,ConditionalType,BeliefType> parameter)
Creates a new instance of AbstractConjugatePriorBayesianEstimator
|
Modifier and Type | Method and Description |
---|---|
AbstractConjugatePriorBayesianEstimator<ObservationType,ParameterType,ConditionalType,BeliefType> |
clone()
This makes public the clone method on the
Object class and
removes the exception that it throws. |
ConditionalType |
createConditionalDistribution(ParameterType parameter)
Creates an instance of the class conditional distribution,
parameterized by the given parameter value.
|
BeliefType |
createInitialLearnedObject()
Creates a new initial learned object, before any data is given.
|
BeliefType |
getInitialBelief()
Getter for initialBelief.
|
BayesianParameter<ParameterType,ConditionalType,BeliefType> |
getParameter()
Gets the Bayesian hyperparameter relationship between the conditional
distribution and the conjugate prior distribution.
|
protected void |
setParameter(BayesianParameter<ParameterType,ConditionalType,BeliefType> parameter)
Setter for parameter
|
learn, learn, update
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
computeEquivalentSampleSize, createParameter
learn
update, update
protected BayesianParameter<ParameterType,ConditionalType extends ClosedFormDistribution<ObservationType>,BeliefType extends ClosedFormDistribution<ParameterType>> parameter
public AbstractConjugatePriorBayesianEstimator(BayesianParameter<ParameterType,ConditionalType,BeliefType> parameter)
parameter
- Bayesian hyperparameter relationship between the conditional
distribution and the conjugate prior distribution.public AbstractConjugatePriorBayesianEstimator<ObservationType,ParameterType,ConditionalType,BeliefType> clone()
AbstractCloneableSerializable
Object
class and
removes the exception that it throws. Its default behavior is to
automatically create a clone of the exact type of object that the
clone is called on and to copy all primitives but to keep all references,
which means it is a shallow copy.
Extensions of this class may want to override this method (but call
super.clone()
to implement a "smart copy". That is, to target
the most common use case for creating a copy of the object. Because of
the default behavior being a shallow copy, extending classes only need
to handle fields that need to have a deeper copy (or those that need to
be reset). Some of the methods in ObjectUtil
may be helpful in
implementing a custom clone method.
Note: The contract of this method is that you must use
super.clone()
as the basis for your implementation.clone
in interface CloneableSerializable
clone
in class AbstractBatchAndIncrementalLearner<ObservationType,BeliefType extends ClosedFormDistribution<ParameterType>>
public BeliefType createInitialLearnedObject()
IncrementalLearner
createInitialLearnedObject
in interface IncrementalLearner<ObservationType,BeliefType extends ClosedFormDistribution<ParameterType>>
public ConditionalType createConditionalDistribution(ParameterType parameter)
ConjugatePriorBayesianEstimator
createConditionalDistribution
in interface ConjugatePriorBayesianEstimator<ObservationType,ParameterType,ConditionalType extends ClosedFormDistribution<ObservationType>,BeliefType extends ClosedFormDistribution<ParameterType>>
parameter
- Parameter used to create the class conditional distribution.public BeliefType getInitialBelief()
public BayesianParameter<ParameterType,ConditionalType,BeliefType> getParameter()
ConjugatePriorBayesianEstimator
getParameter
in interface ConjugatePriorBayesianEstimator<ObservationType,ParameterType,ConditionalType extends ClosedFormDistribution<ObservationType>,BeliefType extends ClosedFormDistribution<ParameterType>>
protected void setParameter(BayesianParameter<ParameterType,ConditionalType,BeliefType> parameter)
parameter
- Bayesian hyperparameter relationship between the conditional
distribution and the conjugate prior distribution.