ParameterType - Type of parameters.ConditionalType - Type of parameterized distribution that generates observations.PriorType - Assumed underlying distribution of parameters of the conditional distribution.public class DefaultBayesianParameter<ParameterType,ConditionalType extends ClosedFormDistribution<?>,PriorType extends Distribution<ParameterType>> extends DefaultDistributionParameter<ParameterType,ConditionalType> implements BayesianParameter<ParameterType,ConditionalType,PriorType>
conditionalDistribution, MEAN_GETTER, MEAN_NAME, MEAN_SETTER, parameterGetter, parameterSettername| Constructor and Description |
|---|
DefaultBayesianParameter(ConditionalType conditionalDistribution,
java.lang.String parameterName)
Creates a new instance of DefaultBayesianParameter
|
DefaultBayesianParameter(ConditionalType conditionalDistribution,
java.lang.String parameterName,
PriorType parameterPrior)
Creates a new instance of DefaultBayesianParameter
|
| Modifier and Type | Method and Description |
|---|---|
DefaultBayesianParameter<ParameterType,ConditionalType,PriorType> |
clone()
This makes public the clone method on the
Object class and
removes the exception that it throws. |
static <ParameterType,ConditionalType extends ClosedFormDistribution<?>,PriorType extends Distribution<ParameterType>> |
create(ConditionalType conditionalDistribution,
java.lang.String parameterName,
PriorType parameterPrior)
Creates a new instance of DefaultBayesianParameter
|
PriorType |
getParameterPrior()
Gets the Distribution of values that the parameter is assumed to take.
|
void |
setParameterPrior(PriorType parameterPrior)
Sets the Distribution of values that the parameter is assumed to take.
|
void |
updateConditionalDistribution(java.util.Random random)
Updates the conditional distribution by sampling from the prior
distribution and assigning through the DistributionParameter.
|
assignParameterMethods, getConditionalDistribution, getValue, setConditionalDistribution, setName, setValuegetName, toStringequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetConditionalDistribution, setValuegetValuepublic DefaultBayesianParameter(ConditionalType conditionalDistribution, java.lang.String parameterName)
conditionalDistribution - Distribution from which to pull the parameters.parameterName - Name of the parameterpublic DefaultBayesianParameter(ConditionalType conditionalDistribution, java.lang.String parameterName, PriorType parameterPrior)
conditionalDistribution - Distribution from which to pull the parameters.parameterName - Name of the parameterparameterPrior - Distribution of values that the parameter is assumed to take.public DefaultBayesianParameter<ParameterType,ConditionalType,PriorType> clone()
AbstractCloneableSerializableObject 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 CloneableSerializableclone in class DefaultDistributionParameter<ParameterType,ConditionalType extends ClosedFormDistribution<?>>public PriorType getParameterPrior()
BayesianParametergetParameterPrior in interface BayesianParameter<ParameterType,ConditionalType extends ClosedFormDistribution<?>,PriorType extends Distribution<ParameterType>>public void setParameterPrior(PriorType parameterPrior)
parameterPrior - Distribution of values that the parameter is assumed to take.public void updateConditionalDistribution(java.util.Random random)
BayesianParameterupdateConditionalDistribution in interface BayesianParameter<ParameterType,ConditionalType extends ClosedFormDistribution<?>,PriorType extends Distribution<ParameterType>>random - Random number generator to use in sampling.public static <ParameterType,ConditionalType extends ClosedFormDistribution<?>,PriorType extends Distribution<ParameterType>> DefaultBayesianParameter<ParameterType,ConditionalType,PriorType> create(ConditionalType conditionalDistribution, java.lang.String parameterName, PriorType parameterPrior)
ParameterType - Type of parameters.ConditionalType - Type of parameterized distribution that generates observations.PriorType - Assumed underlying distribution of parameters of the conditional distribution.conditionalDistribution - Distribution from which to pull the parameters.parameterName - Name of the parameterparameterPrior - Distribution of values that the parameter is assumed to take.