public abstract class ContinuousDistribution extends Distribution
Constructor and Description |
---|
ContinuousDistribution() |
Modifier and Type | Method and Description |
---|---|
double |
cdf(double x)
Computes the value of the Cumulative Density Function (CDF) at the given
point.
|
abstract ContinuousDistribution |
clone() |
abstract double[] |
getCurrentVariableValues()
Returns an array, where each value contains the value of a parameter in the distribution.
|
String |
getDescriptiveName()
The descriptive name of a distribution returns the name of the distribution, followed by the parameters of the distribution and their values.
|
abstract String |
getDistributionName()
Return the name of the distribution.
|
static Function |
getFunctionPDF(ContinuousDistribution dist)
Wraps the
pdf(double) function of the given distribution in a
function object for use. |
protected double |
getIntegrationMax() |
protected double |
getIntegrationMin() |
abstract String[] |
getVariables()
Returns an array, where each value contains the name of a parameter in the distribution.
|
double |
invCdf(double p)
Computes the inverse Cumulative Density Function (CDF-1) at
the given point.
|
double |
logPdf(double x)
Computes the log of the Probability Density Function.
|
double |
mean()
Computes the mean value of the distribution
|
double |
mode()
Computes the mode of the distribution.
|
abstract double |
pdf(double x)
Computes the value of the Probability Density Function (PDF) at the given point
|
abstract void |
setUsingData(Vec data)
Attempts to set the variables used by this distribution based on population sample data,
assuming the sample data is from this type of distribution.
|
abstract void |
setVariable(String var,
double value)
Sets one of the variables of this distribution by the name.
|
double |
skewness()
Computes the skewness of the distribution.
|
String |
toString() |
double |
variance()
Computes the variance of the distribution.
|
getFunctionCDF, invCdf, max, median, min, sample, sampleVec, standardDeviation
public double logPdf(double x)
Double.NEGATIVE_INFINITY
would be the true
value. Instead, this method will always return the negative of
Double.MAX_VALUE
. This is to avoid propagating bad values through
computation.x
- the value to get the log(PDF) ofpublic abstract double pdf(double x)
x
- the value to get the PDFpublic double cdf(double x)
Distribution
cdf
in class Distribution
x
- the value to get the CDF ofpublic double invCdf(double p)
Distribution
invCdf
in class Distribution
p
- the probability valuepublic double mean()
Distribution
mean
in class Distribution
public double variance()
Distribution
NaN
may be
returned if the variance is not defined for the current values of the distribution.
Infinity
is a possible value to be returned
by some distributions.variance
in class Distribution
public double skewness()
Distribution
NaN
may be
returned if the skewness is not defined for the current values of the distribution.skewness
in class Distribution
public double mode()
Distribution
NaN
may be returned if the mode is not defined for the current values of the
distribution.mode
in class Distribution
protected double getIntegrationMin()
protected double getIntegrationMax()
public String getDescriptiveName()
public abstract String getDistributionName()
public abstract String[] getVariables()
getCurrentVariableValues()
public abstract double[] getCurrentVariableValues()
getVariables()
getVariables()
public abstract void setVariable(String var, double value)
var
- the variable to setvalue
- the value to setpublic abstract ContinuousDistribution clone()
clone
in class Distribution
public abstract void setUsingData(Vec data)
data
- the data to use to attempt to fit againstpublic static Function getFunctionPDF(ContinuousDistribution dist)
pdf(double)
function of the given distribution in a
function object for use.dist
- the distribution to wrap the pdf ofCopyright © 2017. All rights reserved.