gov.sandia.cognition.statistics.distribution
Class UnivariateGaussian.WeightedMaximumLikelihoodEstimator

java.lang.Object
  extended by gov.sandia.cognition.util.AbstractCloneableSerializable
      extended by gov.sandia.cognition.statistics.distribution.UnivariateGaussian.WeightedMaximumLikelihoodEstimator
All Implemented Interfaces:
BatchLearner<Collection<? extends WeightedValue<? extends Double>>,UnivariateGaussian.PDF>, DistributionWeightedEstimator<Double,UnivariateGaussian.PDF>, CloneableSerializable, Serializable, Cloneable
Enclosing class:
UnivariateGaussian

public static class UnivariateGaussian.WeightedMaximumLikelihoodEstimator
extends AbstractCloneableSerializable
implements DistributionWeightedEstimator<Double,UnivariateGaussian.PDF>

Creates a UnivariateGaussian from weighted data

See Also:
Serialized Form

Constructor Summary
UnivariateGaussian.WeightedMaximumLikelihoodEstimator()
          Default constructor
UnivariateGaussian.WeightedMaximumLikelihoodEstimator(double defaultVariance)
          Creates a new instance of WeightedMaximumLikelihoodEstimator
 
Method Summary
 UnivariateGaussian.PDF learn(Collection<? extends WeightedValue<? extends Double>> data)
          Creates a new instance of UnivariateGaussian using a weighted Maximum Likelihood estimate based on the given data
static UnivariateGaussian.PDF learn(Collection<? extends WeightedValue<? extends Number>> data, double defaultVariance)
          Creates a new instance of UnivariateGaussian using a weighted Maximum Likelihood estimate based on the given data
 
Methods inherited from class gov.sandia.cognition.util.AbstractCloneableSerializable
clone
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface gov.sandia.cognition.util.CloneableSerializable
clone
 

Constructor Detail

UnivariateGaussian.WeightedMaximumLikelihoodEstimator

public UnivariateGaussian.WeightedMaximumLikelihoodEstimator()
Default constructor


UnivariateGaussian.WeightedMaximumLikelihoodEstimator

public UnivariateGaussian.WeightedMaximumLikelihoodEstimator(double defaultVariance)
Creates a new instance of WeightedMaximumLikelihoodEstimator

Parameters:
defaultVariance - Amount to add to the variance to keep it from being 0.0
Method Detail

learn

public UnivariateGaussian.PDF learn(Collection<? extends WeightedValue<? extends Double>> data)
Creates a new instance of UnivariateGaussian using a weighted Maximum Likelihood estimate based on the given data

Specified by:
learn in interface BatchLearner<Collection<? extends WeightedValue<? extends Double>>,UnivariateGaussian.PDF>
Parameters:
data - Weighed pairs of data (first is data, second is weight) that was generated by some unknown UnivariateGaussian distribution
Returns:
Maximum Likelihood UnivariateGaussian that generated the data

learn

public static UnivariateGaussian.PDF learn(Collection<? extends WeightedValue<? extends Number>> data,
                                           double defaultVariance)
Creates a new instance of UnivariateGaussian using a weighted Maximum Likelihood estimate based on the given data

Parameters:
data - Weighed pairs of data (first is data, second is weight) that was generated by some unknown UnivariateGaussian distribution
defaultVariance - Amount to add to the variance to keep it from being 0.0
Returns:
Maximum Likelihood UnivariateGaussian that generated the data