public class PoissonPD extends ProbabilityDistribution implements Serializable, Cloneable, PDFHessianInterface, ClosedFormMaximumLikelihoodInterface
Constructor and Description |
---|
PoissonPD()
Constructor for the Poisson probability distribution.
|
Modifier and Type | Method and Description |
---|---|
double[] |
getClosedFormMLE(double[] x)
Returns the closed form maximum likelihood estimate.
|
double[] |
getClosedFormMlStandardError(double[] x)
Returns the standard error based on the closed form maximum likelihood estimate.
|
double[] |
getMethodOfMomentsEstimates(double[] x)
Returns the method-of-moments estimate given the sample data.
|
double[] |
getParameterLowerBounds()
Returns the lower bound of the parameter.
|
double[] |
getParameterUpperBounds()
Returns the upper bound of the parameter.
|
double[] |
getPDFGradient(double x,
double... params)
Returns the analytic gradient of the pdf.
|
double[][] |
getPDFHessian(double x,
double... params)
Returns the analytic Hessian matrix of the pdf.
|
double |
pdf(double x,
double... params)
Returns the value of the Poisson probability density function.
|
getNumberOfParameters, getPDFGradientApproximation, getPDFHessianApproximation, getRangeOfX, setRangeOfX
public PoissonPD()
public double[] getParameterLowerBounds()
getParameterLowerBounds
in class ProbabilityDistribution
double
array of length 1 containing the lower
bound for \(\theta > 0\)public double[] getParameterUpperBounds()
getParameterUpperBounds
in class ProbabilityDistribution
double
array of length 1 containing the upper
bound for \(\theta >0\)public double pdf(double x, double... params)
The probability density function of the Poisson distribution is $$\begin{array}{ll}f(k|\theta)=e^{-\theta}\theta^k/k! & \mbox{for}\;k=0, 1, 2, \ldots\end{array}$$
pdf
in class ProbabilityDistribution
x
- a double
, the value (quantile) at which
to evaluate the pdf. x
must be a non-negative integer. If
x
is not a whole number the floor()
value will
be used.params
- a double
specifying the parameter, \(\theta\)double
, the probability density at
x
given the parameter valuepublic double[] getPDFGradient(double x, double... params)
getPDFGradient
in interface PDFGradientInterface
x
- a double
, the value at which to evaluate the pdf.
x
must be a non-negative integer. If x
is not a whole number the
floor()
value will be used.params
- a double
, the value of the parameter \(\theta\)double
array containing the first partial
derivative of the pdf with respect to the parameterpublic double[][] getPDFHessian(double x, double... params)
getPDFHessian
in interface PDFHessianInterface
x
- a double
, the value at which to evaluate the Hessian.
x
must be a non-negative integer. If x
is not a
whole number the floor()
value will be used.params
- a double
, the value of the parameter \(\theta\)double
matrix containing the second partial
derivatives of the pdf with respect to the parameterpublic double[] getClosedFormMLE(double[] x)
getClosedFormMLE
in interface ClosedFormMaximumLikelihoodInterface
x
- a double
array containing the datadouble
array containing the maximum likelihood estimatepublic double[] getClosedFormMlStandardError(double[] x)
getClosedFormMlStandardError
in interface ClosedFormMaximumLikelihoodInterface
x
- a double
array containing the datadouble
array containing the standard errorpublic double[] getMethodOfMomentsEstimates(double[] x)
x
- a double
array containing the datadouble
array containing method-of-moments
estimate for the parameter of the Poisson distributionCopyright © 2020 Rogue Wave Software. All rights reserved.