public static class ChiSquareDistribution.PDF extends ChiSquareDistribution implements UnivariateProbabilityDensityFunction
ChiSquareDistribution.CDF, ChiSquareDistribution.PDF
DEFAULT_DEGREES_OF_FREEDOM
Constructor and Description |
---|
PDF()
Default constructor.
|
PDF(ChiSquareDistribution other)
Copy constructor
|
PDF(double degreesOfFreedom)
Creates a new instance of ChiSquareDistribution
|
Modifier and Type | Method and Description |
---|---|
double |
evaluate(double input)
Produces a double output for the given double input
|
java.lang.Double |
evaluate(java.lang.Double input)
Evaluates the function on the given input and returns the output.
|
static double |
evaluate(double x,
double degreesOfFreedom)
Evaluates the chi-square PDF for the given input and DOFs
|
double |
evaluateAsDouble(java.lang.Double input)
Evaluates the scalar function as a double.
|
ChiSquareDistribution.PDF |
getProbabilityFunction()
Gets the distribution function associated with this Distribution,
either the PDF or PMF.
|
double |
logEvaluate(double input)
Evaluate the natural logarithm of the distribution function.
|
double |
logEvaluate(java.lang.Double input)
Evaluate the natural logarithm of the distribution function.
|
static double |
logEvaluate(double x,
double degreesOfFreedom)
Computes the natural logarithm of the PDF.
|
clone, convertFromVector, convertToVector, getCDF, getDegreesOfFreedom, getMaxSupport, getMeanAsDouble, getMinSupport, getVariance, sample, sampleAsDoubles, sampleInto, setDegreesOfFreedom
getMean, sampleAsDouble, sampleAsDoubles, sampleInto
sample, sample
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getCDF, getMean, sampleAsDouble, sampleAsDoubles, sampleInto
getMaxSupport, getMeanAsDouble, getMinSupport, getVariance
sample, sample, sampleInto
clone, convertFromVector, convertToVector
public PDF()
public PDF(double degreesOfFreedom)
degreesOfFreedom
- Number of degrees of freedom in the distribution,
must be greater than 0.0public PDF(ChiSquareDistribution other)
other
- ChiSquareDistribution to copypublic java.lang.Double evaluate(java.lang.Double input)
Evaluator
evaluate
in interface Evaluator<java.lang.Double,java.lang.Double>
evaluate
in interface ScalarFunction<java.lang.Double>
evaluate
in interface UnivariateScalarFunction
input
- The input to evaluate.public double evaluateAsDouble(java.lang.Double input)
ScalarFunction
evaluateAsDouble
in interface ScalarFunction<java.lang.Double>
evaluateAsDouble
in interface UnivariateScalarFunction
input
- The input value.public double evaluate(double input)
UnivariateScalarFunction
evaluate
in interface UnivariateScalarFunction
input
- Input to the Evaluatorpublic static double evaluate(double x, double degreesOfFreedom)
x
- Input to the PDFdegreesOfFreedom
- DOFs of the PDFpublic double logEvaluate(java.lang.Double input)
ProbabilityFunction
logEvaluate
in interface ProbabilityFunction<java.lang.Double>
input
- The input to be evaluatedpublic double logEvaluate(double input)
UnivariateProbabilityDensityFunction
logEvaluate
in interface UnivariateProbabilityDensityFunction
input
- The input value.public static double logEvaluate(double x, double degreesOfFreedom)
x
- Input to the PDFdegreesOfFreedom
- DOFs of the PDFpublic ChiSquareDistribution.PDF getProbabilityFunction()
ComputableDistribution
getProbabilityFunction
in interface ComputableDistribution<java.lang.Double>
getProbabilityFunction
in interface ProbabilityDensityFunction<java.lang.Double>
getProbabilityFunction
in interface SmoothUnivariateDistribution
getProbabilityFunction
in interface UnivariateProbabilityDensityFunction
getProbabilityFunction
in class ChiSquareDistribution