Class ExponentiallyModifiedGaussianDistribution
- java.lang.Object
-
- elki.math.statistics.distribution.ExponentiallyModifiedGaussianDistribution
-
- All Implemented Interfaces:
Distribution
@Alias("exgaussian") public class ExponentiallyModifiedGaussianDistribution extends java.lang.Object implements Distribution
Exponentially modified Gaussian (EMG) distribution (ExGaussian distribution) is a combination of a normal distribution and an exponential distribution.Note that scipy uses a subtly different parameterization.
TODO: implement quantile function!
- Since:
- 0.6.0
- Author:
- Erich Schubert
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classExponentiallyModifiedGaussianDistribution.ParParameterization class-
Nested classes/interfaces inherited from interface elki.math.statistics.distribution.Distribution
Distribution.Parameterizer
-
-
Constructor Summary
Constructors Constructor Description ExponentiallyModifiedGaussianDistribution(double mean, double stddev, double lambda)Constructor for ExGaussian distribution
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description doublecdf(double val)Return the cumulative density function at the given value.static doublecdf(double x, double mu, double sigma, double lambda)Cumulative probability density function (CDF) of an exgauss distribution.doublegetLambda()doublegetMean()doublegetStddev()doublelogpdf(double val)Return the log density of an existing valuestatic doublelogpdf(double x, double mu, double sigma, double lambda)Probability density function of the ExGaussian distribution.doublenextRandom(java.util.Random random)Generate a new random valuedoublepdf(double val)Return the density of an existing valuestatic doublepdf(double x, double mu, double sigma, double lambda)Probability density function of the ExGaussian distribution.doublequantile(double q)Deprecated.Not yet implemented!static doublequantile(double x, double mu, double sigma, double lambda)Deprecated.Not yet implemented!java.lang.StringtoString()Describe the distribution
-
-
-
Method Detail
-
pdf
public double pdf(double val)
Description copied from interface:DistributionReturn the density of an existing value- Specified by:
pdfin interfaceDistribution- Parameters:
val- existing value- Returns:
- distribution density
-
logpdf
public double logpdf(double val)
Description copied from interface:DistributionReturn the log density of an existing value- Specified by:
logpdfin interfaceDistribution- Parameters:
val- existing value- Returns:
- log distribution density
-
cdf
public double cdf(double val)
Description copied from interface:DistributionReturn the cumulative density function at the given value.- Specified by:
cdfin interfaceDistribution- Parameters:
val- existing value- Returns:
- cumulative density
-
quantile
@Deprecated public double quantile(double q)
Deprecated.Not yet implemented!Description copied from interface:DistributionQuantile aka probit (for normal) aka inverse CDF (invcdf, cdf^-1) function.- Specified by:
quantilein interfaceDistribution- Parameters:
q- Quantile to find- Returns:
- Quantile position
-
nextRandom
public double nextRandom(java.util.Random random)
Description copied from interface:DistributionGenerate a new random value- Specified by:
nextRandomin interfaceDistribution- Parameters:
random- Random number generator- Returns:
- new random value
-
toString
public java.lang.String toString()
Description copied from interface:DistributionDescribe the distribution- Specified by:
toStringin interfaceDistribution- Overrides:
toStringin classjava.lang.Object- Returns:
- description
-
getMean
public double getMean()
- Returns:
- the mean
-
getStddev
public double getStddev()
- Returns:
- the standard deviation
-
getLambda
public double getLambda()
- Returns:
- the lambda value.
-
pdf
public static double pdf(double x, double mu, double sigma, double lambda)Probability density function of the ExGaussian distribution.- Parameters:
x- The value.mu- The mean.sigma- The standard deviation.lambda- Rate parameter.- Returns:
- PDF of the given exgauss distribution at x.
-
logpdf
public static double logpdf(double x, double mu, double sigma, double lambda)Probability density function of the ExGaussian distribution.- Parameters:
x- The value.mu- The mean.sigma- The standard deviation.lambda- Rate parameter.- Returns:
- PDF of the given exgauss distribution at x.
-
cdf
public static double cdf(double x, double mu, double sigma, double lambda)Cumulative probability density function (CDF) of an exgauss distribution.- Parameters:
x- value to evaluate CDF at.mu- Mean value.sigma- Standard deviation.lambda- Rate parameter.- Returns:
- The CDF of the given exgauss distribution at x.
-
quantile
@Deprecated public static double quantile(double x, double mu, double sigma, double lambda)Deprecated.Not yet implemented!Inverse cumulative probability density function (probit) of an exgauss distribution.- Parameters:
x- value to evaluate probit function at.mu- Mean value.sigma- Standard deviation.lambda- Rate parameter.- Returns:
- The probit of the given exgauss distribution at x.
-
-