Interface Distribution

  • All Superinterfaces:
    java.io.Serializable
    All Known Implementing Classes:
    AbstractDistribution, GaussianDistribution, Mixture

    public interface Distribution
    extends java.io.Serializable
    Probability distribution of univariate random variable. A probability distribution identifies either the probability of each value of a random variable (when the variable is discrete), or the probability of the value falling within a particular interval (when the variable is continuous). When the random variable takes values in the set of real numbers, the probability distribution is completely described by the cumulative distribution function, whose value at each real x is the probability that the random variable is smaller than or equal to x.
    Author:
    Haifeng Li
    See Also:
    MultivariateDistribution
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      double cdf​(double x)
      Cumulative distribution function.
      double entropy()
      Shannon entropy of the distribution.
      double likelihood​(double[] x)
      The likelihood of the sample set following this distribution.
      double logLikelihood​(double[] x)
      The log likelihood of the sample set following this distribution.
      double logp​(double x)
      The density at x in log scale, which may prevents the underflow problem.
      double mean()
      The mean of distribution.
      int npara()
      The number of parameters of the distribution.
      double p​(double x)
      The probability density function for continuous distribution or probability mass function for discrete distribution at x.
      double quantile​(double p)
      The quantile, the probability to the left of quantile is p.
      double rand()
      Generates a random number following this distribution.
      double sd()
      The standard deviation of distribution.
      double var()
      The variance of distribution.
    • Method Detail

      • npara

        int npara()
        The number of parameters of the distribution.
      • mean

        double mean()
        The mean of distribution.
      • var

        double var()
        The variance of distribution.
      • sd

        double sd()
        The standard deviation of distribution.
      • entropy

        double entropy()
        Shannon entropy of the distribution.
      • rand

        double rand()
        Generates a random number following this distribution.
      • p

        double p​(double x)
        The probability density function for continuous distribution or probability mass function for discrete distribution at x.
      • logp

        double logp​(double x)
        The density at x in log scale, which may prevents the underflow problem.
      • cdf

        double cdf​(double x)
        Cumulative distribution function. That is the probability to the left of x.
      • quantile

        double quantile​(double p)
        The quantile, the probability to the left of quantile is p. It is actually the inverse of cdf.
      • likelihood

        double likelihood​(double[] x)
        The likelihood of the sample set following this distribution.
      • logLikelihood

        double logLikelihood​(double[] x)
        The log likelihood of the sample set following this distribution.