The beta distribution
The beta distribution describes quantities between 0 and 1, such as proportions, probabilities and percentages. Its two shape parameters α and β make it remarkably flexible: uniform, bell-shaped, U-shaped or skewed to either side.
Key formulas
Density: f(x) = x^(α−1) (1 − x)^(β−1) ÷ B(α, β), where B(α, β) = Γ(α)Γ(β) ÷ Γ(α + β)
Mean = α ÷ (α + β)
Variance = αβ ÷ [(α + β)² (α + β + 1)]
Mode = (α − 1) ÷ (α + β − 2) when α and β are both above 1
The cumulative probability P(X ≤ x) is the regularized incomplete beta function I_x(α, β).
Example
α = 2 and β = 5, for x = 0.3:
- P(X ≤ 0.3) ≈ 0.580;
- mean ≈ 0.286, mode 0.2;
- variance ≈ 0.0255, so a standard deviation of about 0.16.
Bayesian updating of a proportion
The beta distribution is the natural model for an unknown proportion. Start with a prior Beta(α, β); after observing s successes and f failures, the posterior is Beta(α + s, β + f).
For example, with a uniform prior Beta(1, 1), a conversion test with 1 success and 4 failures gives Beta(2, 5): the most likely conversion rate is 20%, and there is a 58% chance that it is below 30%. Each new observation simply adds to α or β.
Shapes
| Parameters | Shape |
|---|---|
| α = β = 1 | Uniform on 0 to 1 |
| α = β > 1 | Symmetric bell around 0.5 |
| α = β < 1 | U-shaped, mass near 0 and 1 |
| α > β | Skewed toward 1 |
| α < β | Skewed toward 0 |
Uses
- A/B testing and click-through rates in Bayesian analysis.
- Project management: the PERT method uses a beta distribution for task durations between an optimistic and a pessimistic estimate.
- Modeling the fraction of time a machine is busy, or the share of a budget spent.
- Order statistics: the k-th smallest of n uniform values follows Beta(k, n − k + 1).
For counts of successes in a fixed number of trials, use the binomial calculator; the beta distribution describes uncertainty about the success probability itself.