Lemma
← All topics
Statistics

Statistical distributions

Models for counts and measurements.

Introduction

A random variable turns the outcome of an experiment into a number. A probability distribution lists every value it can take with its probability. This topic covers discrete distributions in general, the binomial distribution for counting successes, the normal distribution for continuous measurements, finding unknown means and standard deviations, and using the normal distribution to approximate the binomial.

Why it matters

How many of 20 seeds will germinate? How likely is a randomly chosen person to be taller than 1.9 m? The binomial and normal distributions answer questions like these, and they are the engines behind the hypothesis tests used in medicine, manufacturing and science.

Intuitive explanation

IntuitionBinomial: counting successes

Flip a biased coin nn times. Getting exactly rr heads needs some arrangement of rr heads and n−rn - r tails. Each arrangement has probability pr(1−p)n−rp^r(1 - p)^{n - r}, and there are (nr)\binom nr arrangements. Multiply.

IntuitionNormal: the bell curve

Many measurements (heights, errors, exam marks) cluster around a mean, with values further away increasingly rare, symmetrically. The normal curve captures this. Every normal distribution is the standard one Z∼N(0,1)Z \sim N(0, 1) stretched by σ\sigma and shifted by μ\mu, so Z=X−μσZ = \frac{X - \mu}{\sigma} converts between them.

Formal definitions

DefinitionDiscrete random variable

XX takes values x1,x2,…x_1, x_2, \dots with P(X=xi)P(X = x_i), where ∑P(X=xi)=1\sum P(X = x_i) = 1.

DefinitionBinomial distribution

X∼B(n,p)X \sim B(n, p) counts successes in nn independent trials, each with the same success probability pp:

P(X=r)=(nr)pr(1−p)n−r,r=0,1,…,n.P(X = r) = \binom nr p^r (1 - p)^{n - r}, \qquad r = 0, 1, \dots, n.

Mean npnp, variance np(1−p)np(1 - p).

DefinitionNormal distribution

X∼N(μ,σ2)X \sim N(\mu, \sigma^2) is a continuous, symmetric, bell-shaped distribution with mean μ\mu and variance σ2\sigma^2. Probabilities are areas under the curve. Z=X−μσ∼N(0,1)Z = \dfrac{X - \mu}{\sigma} \sim N(0, 1).

Notation

  • P(X≤x)P(X \le x) is the cumulative probability.
  • Φ(z)=P(Z≤z)\Phi(z) = P(Z \le z) for the standard normal.
  • Note N(μ,σ2)N(\mu, \sigma^2) uses the variance: N(50,16)N(50, 16) has standard deviation 44.

Key facts

IdentitiesBinomial conditions

Fixed number of trials nn; two outcomes; independent trials; constant probability pp.

IdentitiesNormal facts
  • About 68%68\% of values lie within 1σ1\sigma of μ\mu, 95%95\% within 2σ2\sigma, 99.7%99.7\% within 3σ3\sigma.
  • Points of inflection at μ±σ\mu \pm \sigma.
  • For continuous XX, P(X=a)=0P(X = a) = 0, so P(X<a)=P(X≤a)P(X < a) = P(X \le a).
IdentitiesCumulative tricks for the binomial

P(X≥a)=1−P(X≤a−1)P(X \ge a) = 1 - P(X \le a - 1), P(a≤X≤b)=P(X≤b)−P(X≤a−1)\quad P(a \le X \le b) = P(X \le b) - P(X \le a - 1).

Key results

TheoremNormal approximation to the binomial

If nn is large and pp is close to 12\frac12 (in practice np>5np > 5 and n(1−p)>5n(1 - p) > 5), B(n,p)≈N(np, np(1−p))B(n, p) \approx N\big(np,\ np(1 - p)\big). Use a continuity correction: P(X≤12)P(X \le 12) becomes P(Y<12.5)P(Y < 12.5).

Why the binomial formula works

ProofCounting arrangements

A particular sequence with rr successes and n−rn - r failures has probability pr(1−p)n−rp^r(1 - p)^{n - r} by independence. The number of such sequences is the number of ways to choose which rr of the nn trials succeed, (nr)\binom nr. These sequences are mutually exclusive, so add: (nr)pr(1−p)n−r\binom nr p^r(1 - p)^{n - r}.

∎

Methods

MethodNormal probabilities

Standardise z=x−μσz = \frac{x - \mu}{\sigma} or use the calculator's normal CDF directly. Sketch the curve and shade the region to check your answer is sensible.

MethodFinding μ\mu or σ\sigma

Use the inverse normal to find zz for a known probability, then solve x−μσ=z\frac{x - \mu}{\sigma} = z. Two conditions give two simultaneous equations.

MethodChoosing a model

Counts of successes out of a fixed number: binomial. Continuous measurements clustered symmetrically: normal. Always check and state the conditions.

Expectation and variance: the rules, derived

For a discrete random variable, E(X)=∑xP(X=x)E(X) = \sum xP(X = x). Three rules follow straight from the definition:

  • Linearity: E(aX+b)=aE(X)+bE(aX + b) = aE(X) + b, because ∑(ax+b)p(x)=a∑xp(x)+b∑p(x)\sum(ax + b)p(x) = a\sum xp(x) + b\sum p(x).
  • Sums: E(X+Y)=E(X)+E(Y)E(X + Y) = E(X) + E(Y) always, even for dependent variables. Write E(X+Y)=∑x,y(x+y)p(x,y)E(X + Y) = \sum_{x,y}(x + y)p(x, y) and split the sum.
  • The variance shortcut: Var⁡(X)=E((X−μ)2)=E(X2)−2μE(X)+μ2=E(X2)−μ2\operatorname{Var}(X) = E\big((X - \mu)^2\big) = E(X^2) - 2\mu E(X) + \mu^2 = E(X^2) - \mu^2.

From the shortcut, Var⁡(aX+b)=a2Var⁡(X)\operatorname{Var}(aX + b) = a^2\operatorname{Var}(X), because a shift moves the mean too and leaves the deviations unchanged.

Why the binomial formula is what it is

A sequence of nn trials with exactly rr successes has probability pr(1−p)n−rp^r(1-p)^{n-r}, whatever the order. There are (nr)\binom nr ways to choose which trials succeed. So P(X=r)=(nr)pr(1−p)n−rP(X = r) = \binom nrp^r(1-p)^{n-r}. The probabilities sum to (p+(1−p))n=1(p + (1 - p))^n = 1 by the binomial theorem, which is where the distribution gets its name.

Standardising

If X∼N(μ,σ2)X \sim N(\mu, \sigma^2), then Z=X−μσZ = \frac{X - \mu}{\sigma} has mean 00 and variance 11, and is still normal. So one table, for Φ(z)=P(Z≤z)\Phi(z) = P(Z \le z), serves every normal distribution.

Examples

ExampleA binomial probability

X∼B(10,0.3)X \sim B(10, 0.3): P(X=2)=(102)(0.3)2(0.7)8=45×0.09×0.05765=0.2335P(X = 2) = \binom{10}{2}(0.3)^2(0.7)^8 = 45 \times 0.09 \times 0.05765 = 0.2335.

See the Worked examples tab for normal distributions, inverse normal and approximations.

Common mistakes

Common mistakeN(μ,σ2)N(\mu, \sigma^2) versus σ\sigma

N(100,225)N(100, 225) has σ=15\sigma = 15, not 225.

Common mistake"At least" with discrete data

P(X≥4)=1−P(X≤3)P(X \ge 4) = 1 - P(X \le 3), not 1−P(X≤4)1 - P(X \le 4).

Common mistakeNo continuity correction

When approximating a discrete distribution by a continuous one, adjust by 0.50.5.

Common mistakeSign of zz

If xx is below the mean, zz is negative. Sketch first.

Applications

  • Quality control: the number of defective items in a batch is binomial.
  • Medicine: reference ranges for blood tests use the normal distribution.
  • Manufacturing: setting machine tolerances so only 1%1\% of parts are rejected.

Connections

Summary

  • B(n,p)B(n, p): P(X=r)=(nr)pr(1−p)n−rP(X = r) = \binom nr p^r(1 - p)^{n - r}; conditions: fixed nn, independent, constant pp, two outcomes.
  • N(μ,σ2)N(\mu, \sigma^2): symmetric bell; Z=X−μσZ = \frac{X - \mu}{\sigma}; inflection points at μ±σ\mu \pm \sigma.
  • Inverse normal to find unknown μ\mu or σ\sigma.
  • B(n,p)≈N(np,np(1−p))B(n, p) \approx N(np, np(1 - p)) with a continuity correction.

Worked examples

Try each one yourself first, then open the solution.

Example 1Cumulative binomial

X∼B(20,0.25)X \sim B(20, 0.25). Find P(3≤X≤7)P(3 \le X \le 7).

Show the solution
  1. 1Rewrite with cumulative probabilities

    P(X≤7)−P(X≤2)P(X \le 7) - P(X \le 2).

  2. 2Values

    P(X≤7)=0.8982P(X \le 7) = 0.8982, P(X≤2)=0.0913P(X \le 2) = 0.0913.

  3. 3Subtract

    0.80690.8069.

Answer

0.80690.8069

Example 2At least one

Each of 12 seeds germinates independently with probability 0.850.85. Find the probability that at least 11 germinate.

Show the solution
  1. 1Model

    X∼B(12,0.85)X \sim B(12, 0.85).

  2. 2Two terms

    P(X=11)=12(0.85)11(0.15)=0.3012P(X = 11) = 12(0.85)^{11}(0.15) = 0.3012; P(X=12)=0.8512=0.1422P(X = 12) = 0.85^{12} = 0.1422.

  3. 3Add

    0.44350.4435.

Answer

0.44350.4435

Example 3A normal probability

Heights H∼N(170,82)H \sim N(170, 8^2) cm. Find P(160<H<185)P(160 < H < 185).

Show the solution
  1. 1Standardise

    z1=160−1708=−1.25z_1 = \frac{160 - 170}{8} = -1.25, z2=185−1708=1.875z_2 = \frac{185 - 170}{8} = 1.875.

  2. 2Probability

    Φ(1.875)−Φ(−1.25)=0.9696−0.1056=0.8640\Phi(1.875) - \Phi(-1.25) = 0.9696 - 0.1056 = 0.8640.

Answer

0.8640.864

Example 4Finding the mean

X∼N(μ,52)X \sim N(\mu, 5^2) and P(X>40)=0.2P(X > 40) = 0.2. Find μ\mu.

Show the solution
  1. 1Inverse normal

    P(Z>z)=0.2⇒z=0.8416P(Z > z) = 0.2 \Rightarrow z = 0.8416.

  2. 2Equation

    40−μ5=0.8416\frac{40 - \mu}{5} = 0.8416.

  3. 3Solve

    μ=40−4.208=35.8\mu = 40 - 4.208 = 35.8.

Answer

μ=35.8\mu = 35.8

Example 5Finding both parameters

X∼N(μ,σ2)X \sim N(\mu, \sigma^2), P(X<20)=0.1P(X < 20) = 0.1 and P(X>50)=0.05P(X > 50) = 0.05. Find μ\mu and σ\sigma.

Show the solution
  1. 1z-values

    P(Z<−1.2816)=0.1P(Z < -1.2816) = 0.1; P(Z>1.6449)=0.05P(Z > 1.6449) = 0.05.

  2. 2Equations

    μ−1.2816σ=20\mu - 1.2816\sigma = 20 and μ+1.6449σ=50\mu + 1.6449\sigma = 50.

  3. 3Solve

    Subtract: 2.9265σ=30⇒σ=10.252.9265\sigma = 30 \Rightarrow \sigma = 10.25; μ=33.1\mu = 33.1.

Answer

μ=33.1\mu = 33.1, σ=10.3\sigma = 10.3

Example 6Normal approximation

X∼B(100,0.4)X \sim B(100, 0.4). Use a normal approximation to estimate P(X≤35)P(X \le 35).

Show the solution
  1. 1Approximating distribution

    μ=40\mu = 40, σ2=24\sigma^2 = 24: Y∼N(40,24)Y \sim N(40, 24).

  2. 2Continuity correction

    P(X≤35)≈P(Y<35.5)P(X \le 35) \approx P(Y < 35.5).

  3. 3Evaluate

    z=35.5−4024=−0.9186z = \frac{35.5 - 40}{\sqrt{24}} = -0.9186, probability 0.17920.1792.

Answer

≈0.179\approx 0.179 (exact binomial 0.17950.1795)

Example 7A discrete distribution

P(X=x)=kxP(X = x) = kx for x=1,2,3,4x = 1, 2, 3, 4. Find kk and P(X≥3)P(X \ge 3).

Show the solution
  1. 1Probabilities sum to 1

    k(1+2+3+4)=10k=1⇒k=0.1k(1 + 2 + 3 + 4) = 10k = 1 \Rightarrow k = 0.1.

  2. 2Required probability

    P(X≥3)=0.3+0.4=0.7P(X \ge 3) = 0.3 + 0.4 = 0.7.

Answer

k=0.1k = 0.1, 0.70.7

Beyond the specification

University-level ideas and the deeper mathematics behind this topic. Not needed for exams, but this is where the subject really opens up.

The Gaussian integral (university)

The normal density contains 12π\frac{1}{\sqrt{2\pi}} because of one remarkable integral.

TheoremThe Gaussian integral
∫−∞∞e−x2 dx=π.\int_{-\infty}^{\infty}e^{-x^2}\,dx = \sqrt\pi.
ProofPoisson's trick: square it

Let II be the integral. Then

I2=∫−∞∞e−x2 dx∫−∞∞e−y2 dy=∬R2e−(x2+y2) dx dy.I^2 = \int_{-\infty}^\infty e^{-x^2}\,dx\int_{-\infty}^\infty e^{-y^2}\,dy = \iint_{\mathbb R^2}e^{-(x^2 + y^2)}\,dx\,dy.

Change to polar coordinates, with x2+y2=r2x^2 + y^2 = r^2 and dx dy=r dr dθdx\,dy = r\,dr\,d\theta:

I2=∫02π∫0∞e−r2r dr dθ=2π[−12e−r2]0∞=π.I^2 = \int_0^{2\pi}\int_0^\infty e^{-r^2}r\,dr\,d\theta = 2\pi\left[-\tfrac12e^{-r^2}\right]_0^\infty = \pi.

Since I>0I > 0, I=πI = \sqrt\pi. ■\blacksquare

∎

The extra factor of rr in polar coordinates is what makes e−r2re^{-r^2}r integrable in closed form. There is no elementary antiderivative of e−x2e^{-x^2} (Liouville's theorem), so Φ\Phi has no formula and must be tabulated or computed numerically. Only the integral over the whole line can be found exactly.

Mathematical curiosityΓ(½) = √π

With x=tx = \sqrt t, the Gaussian integral becomes Γ(12)=∫0∞t−1/2e−t dt=π\Gamma\left(\frac12\right) = \int_0^\infty t^{-1/2}e^{-t}\,dt = \sqrt\pi, linking the normal distribution to the Gamma function from the Integration lesson. It also gives the volume of an nn-dimensional ball: πn/2Γ(n/2+1)rn\frac{\pi^{n/2}}{\Gamma(n/2 + 1)}r^n.

The central limit theorem (university)

The deepest reason the normal distribution matters.

TheoremCentral limit theorem

Let X1,X2,…X_1, X_2, \ldots be independent with the same distribution, mean μ\mu and finite variance σ2\sigma^2. Then

X1+⋯+Xn−nμσn⟶N(0,1)in distribution.\frac{X_1 + \cdots + X_n - n\mu}{\sigma\sqrt n} \longrightarrow N(0, 1)\quad\text{in distribution.}

The original distribution can be anything: a coin, a die, waiting times, incomes. Only the mean and variance survive in the limit. Every other feature is washed out.

ProofSketch, by moment generating functions

Take μ=0\mu = 0 and σ=1\sigma = 1, and let Sn=1n∑XiS_n = \frac{1}{\sqrt n}\sum X_i. By independence,

MSn(t)=[M(tn)]n.M_{S_n}(t) = \left[M\left(\tfrac{t}{\sqrt n}\right)\right]^n.

Taylor-expand: M(s)=1+0⋅s+s22+o(s2)M(s) = 1 + 0\cdot s + \frac{s^2}{2} + o(s^2), using E(X)=0E(X) = 0 and E(X2)=1E(X^2) = 1. So

MSn(t)=(1+t22n+o(1n))n→et2/2,M_{S_n}(t) = \left(1 + \frac{t^2}{2n} + o\left(\tfrac1n\right)\right)^n \to e^{t^2/2},

which is the MGF of N(0,1)N(0, 1). A continuity theorem (Lévy) turns convergence of the generating functions into convergence of the distributions. ■\blacksquare (The rigorous proof uses characteristic functions E(eitX)E(e^{itX}), which always exist.)

∎
ExampleWhy √n

Averaging nn measurements reduces the standard deviation by a factor n\sqrt n: SD⁡(Xˉ)=σn\operatorname{SD}(\bar X) = \frac{\sigma}{\sqrt n}. Quadrupling a survey's size halves its margin of error. This is why polls of about 10001000 people give roughly ±3%\pm3\% (1.96×0.25/1000≈0.0311.96\times\sqrt{0.25/1000} \approx 0.031).

CounterexampleWhen the CLT fails

The Cauchy distribution, with density 1π(1+x2)\frac{1}{\pi(1 + x^2)}, has no mean and no variance. The average of nn independent Cauchy variables is again standard Cauchy, exactly, for every nn. Averaging does not help at all. Heavy-tailed data (financial crashes, earthquake sizes, city populations) can behave like this, and models that assume normality then badly underestimate extreme events.

HistoryFrom de Moivre to Lyapunov

De Moivre (1733) found the normal curve as the limit of the binomial (question Q60). Laplace (1812) extended it to general sums. Lyapunov (1901) gave the first rigorous general proof, and Lindeberg (1922) found the sharp conditions.

The family of distributions (university)

The standard distributions are not a list of unrelated formulas. They are a family, connected by limits, sums and transformations.

DistributionModelsMeanVariance
Bernoulli(p)(p)one trialppp(1−p)p(1-p)
Binomial(n,p)(n, p)successes in nn trialsnpnpnp(1−p)np(1-p)
Geometric(p)(p)trials until the first success1p\frac1p1−pp2\frac{1-p}{p^2}
Poisson(λ)(\lambda)rare events in a fixed timeλ\lambdaλ\lambda
Exponential(λ)(\lambda)waiting time1λ\frac1\lambda1λ2\frac1{\lambda^2}
Gamma(k,λ)(k, \lambda)waiting time for kk eventskλ\frac k\lambdakλ2\frac{k}{\lambda^2}
Normal(μ,σ2)(\mu, \sigma^2)sums of many effectsμ\muσ2\sigma^2
Uniform[a,b][a, b]no preferencea+b2\frac{a+b}2(b−a)212\frac{(b-a)^2}{12}

The connections

  • Sum of Bernoullis is binomial (questions Q42, Q43).
  • Binomial → Poisson as n→∞n \to \infty with np=λnp = \lambda fixed (question Q53).
  • Binomial → normal as n→∞n \to \infty with pp fixed (CLT).
  • Geometric → exponential: the continuous analogue, and the only memoryless distributions of their kind (questions Q46, Q55).
  • Poisson process: counts in time tt are Poisson(λt)(\lambda t), and the gaps between events are exponential(λ)(\lambda). Two views of the same randomness.
  • Sum of kk exponentials is Gamma(k,λ)(k, \lambda); as kk grows, it becomes normal.
  • Squares of normals: Z12+⋯+Zk2Z_1^2 + \cdots + Z_k^2 has the χk2\chi^2_k distribution, a Gamma. It is the basis of the chi-squared test and of sample variances.
Beyond the syllabusExponential families

Most of the table has densities of the form h(x)exp⁡(ηT(x)−A(η))h(x)\exp\big(\eta T(x) - A(\eta)\big). This exponential family structure explains why these distributions have simple sufficient statistics, conjugate Bayesian priors (Beta for binomial, Gamma for Poisson) and neat maximum likelihood estimates. It also underlies generalised linear models such as logistic regression.

Entropy and why the normal is natural (university)

How much uncertainty does a distribution contain? Shannon (1948) gave the answer.

DefinitionEntropy

For a discrete distribution, H=−∑pilog⁡2piH = -\sum p_i\log_2p_i bits. For a continuous density, the differential entropy is h=−∫fln⁡f dxh = -\int f\ln f\,dx.

A fair coin has H=1H = 1 bit. A coin with p=0.9p = 0.9 has H=0.469H = 0.469 bits: less uncertain, so its outcomes can be compressed. Entropy is exactly the limit of lossless compression, which is why it underpins ZIP files and every digital communication system.

TheoremMaximum entropy
  • Among distributions on nn outcomes, the uniform has maximum entropy, log⁡2n\log_2n.
  • Among densities on [0,∞)[0, \infty) with a given mean, the exponential has maximum entropy.
  • Among densities on R\mathbb R with a given mean and variance, the normal has maximum entropy, 12ln⁡(2πeσ2)\frac12\ln(2\pi e\sigma^2).
ProofSketch, by Gibbs' inequality

For any densities ff and gg, ∫fln⁡fg≥0\int f\ln\frac fg \ge 0 (because ln⁡x≤x−1\ln x \le x - 1). Take gg to be the normal with the same mean and variance as ff. Then −∫fln⁡g-\int f\ln g depends only on the first two moments of ff, which match those of gg. So h(f)≤−∫fln⁡g=h(g)h(f) \le -\int f\ln g = h(g). ■\blacksquare

∎

This is the modern justification for using normal models: if all you know is a mean and a variance, the normal distribution assumes the least beyond that. The CLT says the normal is where sums end up; maximum entropy says it is the most honest assumption. In statistical physics, the same principle produces the Maxwell–Boltzmann distribution of molecular speeds.

Why does this work?

Why does this work?Why does the binomial look normal for large nn?

A binomial count is a sum of nn independent 0/1 variables. The central limit theorem says that the sum of many independent variables with finite variance, standardised, is approximately N(0,1)N(0, 1), whatever their individual distribution. That is why the normal curve appears everywhere: heights, measurement errors and exam totals are all sums of many small effects.

Beyond the syllabus

Beyond the syllabusThe central limit theorem

If X1,X2,…X_1, X_2, \dots are independent and identically distributed with mean μ\mu and variance σ2\sigma^2, then Xˉn−μσ/n\frac{\bar X_n - \mu}{\sigma/\sqrt n} converges in distribution to N(0,1)N(0, 1). One proof uses moment generating functions MX(t)=E[etX]M_X(t) = E[e^{tX}]: the MGF of a sum of independent variables is the product of their MGFs, and (1+t22n+o(1n))n→et2/2\left(1 + \frac{t^2}{2n} + o\left(\frac1n\right)\right)^n \to e^{t^2/2}, the MGF of N(0,1)N(0, 1).

Beyond the syllabusThe Poisson distribution as a limit

Let n→∞n \to \infty with np=λnp = \lambda fixed. Then (nr)pr(1−p)n−r→e−λλrr!\binom nr p^r(1 - p)^{n-r} \to e^{-\lambda}\frac{\lambda^r}{r!}. Rare events among many trials (typing errors, radioactive decays, goals in a match) follow a Poisson distribution.

Mathematical curiosities

Mathematical curiosityGalton's board

Balls dropping through rows of pegs, bouncing left or right with probability 12\frac12, pile up in a binomial shape that looks like a bell curve. It is a physical demonstration of the central limit theorem.

Further exploration

Further explorationInvestigations
  • Show that E(X)=npE(X) = np for X∼B(n,p)X \sim B(n, p) by differentiating (px+q)n(px + q)^n with respect to xx.
  • Verify numerically that B(100,0.03)B(100, 0.03) is close to Poisson(3).
Now practise60 questions from Very easy to Extreme →