Negative Binomial Distribution Calculator

Reviewed by CalcMulti Editorial Team·Last updated: ·Statistics Hub

The negative binomial distribution models the number of failures before achieving r successes in a sequence of independent Bernoulli trials, each with success probability p. When r = 1, it reduces to the geometric distribution.

Enter the number of successes r, success probability p, and an optional k (number of failures) to compute probabilities. The calculator shows PMF, CDF, mean, variance, and a full probability table.

Formula

P(X = k) = C(k+r−1, k) × p^r × (1−p)^k

r
number of successes required (target)
p
probability of success on each trial
k
number of failures before the r-th success (k = 0, 1, 2, …)
C(k+r−1, k)
ways to arrange k failures in k+r−1 trials

Parameters

Positive integer

0 < p < 1

P(X = k) and P(X ≤ k)

Distribution Comparison for Count Data

DistributionModelsVariance vs MeanUse when
Binomialk successes in n trialsVar < Mean (unless p = 0.5)Fixed n, independent trials
GeometricFailures before 1st successVar = (1−p)/p² > MeanFirst-success timing
Negative BinomialFailures before r-th successVar > Mean (overdispersion)Overdispersed count data
PoissonEvents in time/spaceVar = Mean (equidispersion)Rare events, fixed rate

Disclaimer

For educational and exploratory use only. For large r, the normal approximation to the negative binomial may be more practical.

Frequently Asked Questions