Interface PoissonDistribution
- All Superinterfaces:
DiscreteDistribution,Distribution,IntegerDistribution
- All Known Implementing Classes:
PoissonDistributionImpl
Interface representing the Poisson Distribution.
References:
-
Method Summary
Modifier and TypeMethodDescriptiondoublegetMean()Get the mean for the distribution.doublenormalApproximateProbability(int x) Calculates the Poisson distribution function using a normal approximation.voidsetMean(double p) Deprecated.as of v2.1Methods inherited from interface org.apache.commons.math.distribution.DiscreteDistribution
probabilityMethods inherited from interface org.apache.commons.math.distribution.Distribution
cumulativeProbability, cumulativeProbabilityMethods inherited from interface org.apache.commons.math.distribution.IntegerDistribution
cumulativeProbability, cumulativeProbability, inverseCumulativeProbability, probability
-
Method Details
-
getMean
double getMean()Get the mean for the distribution.- Returns:
- the mean for the distribution.
-
setMean
Deprecated.as of v2.1Set the mean for the distribution. The parameter value must be positive; otherwise anIllegalArgumentis thrown.- Parameters:
p- the mean- Throws:
IllegalArgumentException- if p ≤ 0
-
normalApproximateProbability
Calculates the Poisson distribution function using a normal approximation.- Parameters:
x- the upper bound, inclusive- Returns:
- the distribution function value calculated using a normal approximation
- Throws:
MathException- if an error occurs computing the normal approximation
-