Module 8 · Lesson 8.3

Expectation, Variance & the Normal Distribution

Learn how a distribution's balancing point and spread summarize its whole shape in two numbers.

Intuition

Picture a distribution's histogram cut out of cardboard and balanced on a finger. The point where it balances perfectly, without tipping either way, is the expectation — the long-run average value. How far the weight is spread out from that balancing point is the variance: a tight clump balances easily near the center, while a widely scattered shape needs the finger to support material that's flung far in both directions.

Core concept

Expectation, written $E[X]$, is a weighted average: multiply each possible value by how likely it is, then add those products up. Variance measures spread by averaging the squared distance of each value from that balancing point — squaring keeps distances on either side from cancelling out and punishes values that sit far from the center. Together, expectation and variance are often enough to describe a distribution's shape without ever drawing it.

1 2 3 E[X]=2.1
P(X=1), P(X=2), P(X=3)0.2, 0.5, 0.3
1(0.2) + 2(0.5) + 3(0.3)0.2 + 1.0 + 0.9
AnswerE[X] = 2.1

Interactive Lab

Drag the mean to shift where the curve balances, and drag the spread to squeeze or stretch it. Notice how a wider spread must also flatten the peak.

0.0
1.0

Key Idea

$$ f(x) = \frac{1}{\sigma\sqrt{2\pi}}\, e^{-\frac{(x-\mu)^2}{2\sigma^2}} $$

This is the normal distribution — the bell curve you just shaped in the lab above. It's built entirely from the balancing point $\mu$ and the spread $\sigma$: no other numbers are needed. In fact $\mu$ is exactly $E[X]$, and $\sigma^2$ is exactly the variance, $Var(X)$. Two A/B test groups can share the same mean conversion rate yet have very different variances — the group with the tighter spread gives you a far more confident read on whether a measured difference is real or just noise.

$x$A value the random variable could take
$\mu$The mean — the distribution's balancing point
$\sigma$The standard deviation — how spread out values are from $\mu$
$f(x)$The height of the curve at value $x$

Think Further

  1. Why must the peak of the curve get shorter whenever you increase the spread?
  2. Two A/B test groups have identical mean conversion rates but very different variances. Which one gives you more confidence in the result, and why?
  3. If a distribution has $E[X] = 0$ but a very large variance, what does that tell you about the individual values, even though they average out to zero?
Show suggested answers
  1. The total area under the curve always represents total probability, which must stay fixed at 1. Spreading that area over a wider range means less of it can pile up at any single point, so the peak has to drop.
  2. The group with the smaller variance, because its outcomes cluster tightly around the mean — a measured difference is less likely to be an accident of noisy, widely scattered data.
  3. Large variance with a mean of zero means individual values swing far above and below zero, even though the positive and negative swings cancel out on average — the mean alone hides how volatile any single outcome can be.