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
| Distribution | Models | Variance vs Mean | Use when |
|---|---|---|---|
| Binomial | k successes in n trials | Var < Mean (unless p = 0.5) | Fixed n, independent trials |
| Geometric | Failures before 1st success | Var = (1−p)/p² > Mean | First-success timing |
| Negative Binomial | Failures before r-th success | Var > Mean (overdispersion) | Overdispersed count data |
| Poisson | Events in time/space | Var = Mean (equidispersion) | Rare events, fixed rate |
Related Calculators
Fixed n trials, count successes
Geometric Distribution CalculatorFailures before first success (r = 1 case)
Poisson CalculatorEvent counts with fixed rate
Hypergeometric CalculatorSampling without replacement
Normal Distribution CalculatorLarge-sample approximation
Statistics HubAll statistics calculators
Disclaimer
For educational and exploratory use only. For large r, the normal approximation to the negative binomial may be more practical.