Class MultivariateGaussianEstimator

  • All Implemented Interfaces:
    java.io.Serializable, MultivariateEstimator

    public class MultivariateGaussianEstimator
    extends java.lang.Object
    implements MultivariateEstimator, java.io.Serializable
    Implementation of maximum likelihood Multivariate Distribution Estimation using Normal Distribution.
    Version:
    $Revision: 12904 $
    Author:
    Uday Kamath, PhD, George Mason University, Eibe Frank, University of Waikato
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static double Log2PI
      Log of twice the number pi: log(2*pi).
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void estimate​(double[][] observations, double[] weights)
      Generates the estimator based on the given observations and weight vector.
      double[][] estimatePooled​(double[][][] observations, double[][] weights)
      Generates pooled estimator for linear discriminant analysis based on the given groups of observations and weight vectors.
      double[] getMean()
      Returns the mean vector.
      double getRidge()
      Get the value of Ridge.
      double logDensity​(double[] valuePassed)
      Returns the log of the density value for the given vector.
      static void main​(java.lang.String[] args)
      Main method for testing this class.
      java.lang.String ridgeTipText()
      Returns the tip text for this property
      void setRidge​(double newRidge)
      Set the value of Ridge.
      java.lang.String toString()
      Returns string summarizing the estimator.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • Log2PI

        public static final double Log2PI
        Log of twice the number pi: log(2*pi).
    • Constructor Detail

      • MultivariateGaussianEstimator

        public MultivariateGaussianEstimator()
    • Method Detail

      • toString

        public java.lang.String toString()
        Returns string summarizing the estimator.
        Overrides:
        toString in class java.lang.Object
      • getMean

        public double[] getMean()
        Returns the mean vector.
      • logDensity

        public double logDensity​(double[] valuePassed)
        Returns the log of the density value for the given vector.
        Specified by:
        logDensity in interface MultivariateEstimator
        Parameters:
        valuePassed - input vector
        Returns:
        log density based on given distribution
      • estimate

        public void estimate​(double[][] observations,
                             double[] weights)
        Generates the estimator based on the given observations and weight vector. Equal weights are assumed if the weight vector is null.
        Specified by:
        estimate in interface MultivariateEstimator
        Parameters:
        observations - the value to add
        weights - the weight of the value
      • estimatePooled

        public double[][] estimatePooled​(double[][][] observations,
                                         double[][] weights)
        Generates pooled estimator for linear discriminant analysis based on the given groups of observations and weight vectors. The pooled covariance matrix is the weighted mean of the per-group covariance matrices. The pooled mean vector is the mean vector for all observations.
        Returns:
        the per group mean vectors
      • ridgeTipText

        public java.lang.String ridgeTipText()
        Returns the tip text for this property
        Returns:
        tip text for this property suitable for displaying in the explorer/experimenter gui
      • getRidge

        public double getRidge()
        Get the value of Ridge.
        Returns:
        Value of Ridge.
      • setRidge

        public void setRidge​(double newRidge)
        Set the value of Ridge.
        Parameters:
        newRidge - Value to assign to Ridge.
      • main

        public static void main​(java.lang.String[] args)
        Main method for testing this class.
        Parameters:
        args - command-line parameters