St · Statistics & Probability

How to Find the Inverse of a Poisson Distribution Function

Published By the 9to5Science editorial team

At a glance

  1. 1. Set the inputs

    Choose the Poisson mean λ and a cumulative probability p between 0 and 1.

  2. 2. Compute cumulative probabilities

    Evaluate the probability of at most k events for successive nonnegative integers k.

  3. 3. Choose the first match

    The inverse is the smallest k whose cumulative probability is at least p.

The inverse of a Poisson distribution function usually means its quantile function: given a mean λ and a cumulative probability p, find the event count at which the cumulative probability reaches p. Because a Poisson random variable takes only integer values, this inverse is a stepwise function rather than a smooth algebraic formula.

Define the inverse Poisson CDF

Let XX have a Poisson distribution with mean λ, where λ > 0. Its probability mass function is

P(X=j)=e−λλjj!,j=0,1,2,…P(X=j)=e^{-\lambda}\frac{\lambda^j}{j!}, \qquad j=0,1,2,\ldots

The cumulative distribution function (CDF) at a nonnegative integer k is

F(k;λ)=P(X≤k)=e−λ∑j=0kλjj!.F(k;\lambda)=P(X\le k)=e^{-\lambda}\sum_{j=0}^{k}\frac{\lambda^j}{j!}.

For a probability 0<p<10<p<1, the inverse CDF, also called the quantile, is

F−1(p;λ)=min⁡{k∈{0,1,2,…}:F(k;λ)≥p}.F^{-1}(p;\lambda)=\min\{k\in\{0,1,2,\ldots\}:F(k;\lambda)\ge p\}.

In words, start at zero and choose the first integer whose cumulative probability is at least p. Since the Poisson distribution has an unbounded range, the quantile is finite for every p strictly between 0 and 1. At p = 1 there is no finite quantile; some software reports infinity. Endpoint conventions at p = 0 vary, but the usual support-based convention returns 0.

Find the quantile by accumulating probabilities

A direct method is to calculate the probability for each count and keep a running total. Stop as soon as that total is at least p.

For example, suppose X∼Poisson⁡(3)X\sim\operatorname{Poisson}(3) and you want the inverse CDF at p=0.8p=0.8. The probabilities and cumulative totals are approximately:

Count kP(X=k)P(X=k)P(X≤k)P(X\le k)
00.049790.04979
10.149360.19915
20.224040.42319
30.224040.64723
40.168030.81526

At k = 3 the cumulative probability is only about 0.64723, which is below 0.8. At k = 4 it is about 0.81526, which reaches or exceeds 0.8. Therefore,

F−1(0.8;3)=4.F^{-1}(0.8;3)=4.

Notice that the CDF does not equal 0.8 at an integer in this example. The quantile is still well defined: it is the first integer where the CDF crosses the requested probability.

For larger means, a calculator or statistical package is more convenient. Look for a Poisson quantile or inverse-CDF function, and check its parameter order: many functions take the probability first and the mean second, but conventions differ. For instance, in R the call is qpois(0.8, lambda = 3); it returns 4.

Why there is no ordinary inverse formula

The CDF is constant between integer counts and jumps at the integers. It therefore cannot have an ordinary, one-to-one inverse over the real numbers. The generalized inverse above handles this by returning the smallest count at which the CDF reaches the requested level.

The CDF can also be written using the regularized upper incomplete gamma function QQ:

F(k;λ)=Q(k+1,λ).F(k;\lambda)=Q(k+1,\lambda).

This identity can be useful in mathematical software, but it does not turn the inverse quantile into an elementary formula. In practice, software finds the integer quantile using numerical evaluation and search.

If you meant solving for the mean

Sometimes “inverse” means finding λ when a count k and a cumulative probability p are given. That is a different problem: solve

F(k;λ)=pF(k;\lambda)=p

for λ. For a fixed nonnegative k, F(k;λ)F(k;\lambda) decreases as λ increases, so a numerical root finder can locate the mean that gives the specified probability. Be clear about which quantity is unknown: the ordinary inverse CDF returns an integer count from λ and p, while this alternative solves for λ from k and p.

Common mistakes

  • Using the probability of exactly k events. The inverse CDF uses P(X≤k)P(X\le k), the sum of probabilities from 0 through k, not just P(X=k)P(X=k).
  • Rounding to the nearest count. Do not round a continuous approximation to get the exact quantile. Choose the smallest integer whose CDF is at least p.
  • Confusing the mean with the quantile. λ is the distribution’s mean; the quantile depends on both λ and p and is generally not equal to λ.
  • Mixing up lower and upper tails. The definition here uses the lower-tail probability P(X≤k)P(X\le k). A request involving P(X≥k)P(X\ge k) or an upper-tail probability may require a different inequality or a complementary probability.

References

  1. NIST Digital Library of Mathematical Functions, §8.2: Incomplete Gamma Functions
  2. Probability and Statistics for Engineering and the Sciences, Jay L. Devore

Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.