Mean and Variance of X-bar

Unbiased, with variance divided by n.

The sample mean as a random variable

Take a sample of n values, X₁, X₂, up to Xₙ, each drawn at random from a population with mean μ and variance σ². Their mean is X̄ = (X₁ + X₂ + … + Xₙ) / n, read “X-bar”.

Each Xᵢ is a random variable with mean μ and variance σ², and X̄ is a random variable too: a different sample gives a different value. Its mean and its variance can be worked out from μ, σ² and n.

The mean of X̄ is μ

Expected values add, so E(X₁ + X₂ + … + Xₙ) = μ + μ + … + μ = nμ. Dividing the total by n divides its expected value by n, so E(X̄) = nμ / n = μ.

On average, then, the sample mean equals the population mean. A single sample mean can be too high or too low, but it does not tend to miss in either direction. An estimate with this property is called unbiased, and X̄ is an unbiased estimator of μ.

One dice and two

Roll a fair dice. The score X is 1, 2, 3, 4, 5 or 6, each with probability 1/6, so μ = 3.5. Its variance is σ² = 35/12 ≈ 2.917.

Now roll two dice and take the mean of the two scores. There are 6 × 6 = 36 equally likely outcomes, and the mean can be 1, 1.5, 2, and so on up to 6. Only one outcome gives a mean of 1 (two ones), but six outcomes give 3.5. The mean of two dice is still centered on 3.5, and it is far more likely to be near 3.5 than a single score is.

Working through all 36 outcomes, the variance of the mean of two dice is 35/24 ≈ 1.458. That is exactly half of 35/12: with n = 2, the variance has been divided by 2.

123456

One dice: each score from 1 to 6 has probability 6/36 = 1/6.

123456

The mean of two dice, in steps of 0.5 from 1 to 6, counted out of the 36 outcomes: 1, 2, 3, 4, 5, 6, 5, 4, 3, 2, 1. The center is still 3.5, and the ends are now rare.

The variance of X̄ is σ²/n

When the values in the sample are independent, their variances add: Var(X₁ + X₂ + … + Xₙ) = σ² + σ² + … + σ² = nσ².

Dividing a random variable by n divides its variance by n², because variance is measured in squared units: if every value is divided by n, every squared distance from the mean is divided by n². So Var(X̄) = nσ² / n². One n cancels, and Var(X̄) = σ²/n.

For the two dice, σ²/n = (35/12) / 2 = 35/24, the value found from the 36 outcomes.

One egg and twenty-five

The masses of eggs from a farm are normally distributed with mean 62 g and standard deviation 5 g, so σ² = 25. For the mean mass of 25 eggs, E(X̄) = 62 g and Var(X̄) = 25 ÷ 25 = 1, so the standard deviation of X̄ is √1 = 1 g.

About a third of single eggs, a proportion of 0.317, weigh more than 5 g away from 62 g. The mean of 25 eggs is more than 2 g away from 62 g with probability only 0.046.

mass (g)

The low, wide dashed curve is the mass of one egg, with standard deviation 5 g. The tall gold curve is the mean of 25 eggs, with standard deviation 1 g. Both are centered on 62 g, and each encloses an area of 1.

Larger samples, tighter estimates

Because n is in the denominator, every extra observation makes Var(X̄) a little smaller. With σ² = 36, a sample of 4 gives Var(X̄) = 36 ÷ 4 = 9, a sample of 9 gives 36 ÷ 9 = 4, and a sample of 36 gives 36 ÷ 36 = 1.

The standard deviation of X̄ is the square root: 3, then 2, then 1. Going from 4 readings to 36, nine times as many, divides the variance by 9 but the standard deviation only by 3. The spread shrinks with the square root of n. The standard deviation of X̄, σ/√n, is called the standard error.

When the values are not independent

The variances add only when the values in the sample are independent. That holds when sampling with replacement, and very nearly holds when the sample is a small part of a large population.

Drawing without replacement from a small population breaks it. The ten scores 3, 5, 4, 8, 2, 6, 5, 7, 4 and 6 have mean 5 and variance 3. The means of all 210 samples of four, drawn without replacement, do average 5, as E(X̄) = μ says. But their variance is 0.5, not 3 ÷ 4 = 0.75: once the 8 is in a sample it cannot be drawn again, and that makes extreme samples rarer still.

The usual mistakes

Keeping the population variance. σ² is the variance of one value; the mean of n values has variance σ²/n.

Dividing the variance by n² and stopping. The variances add to nσ² first, so dividing by n² leaves σ²/n.

Dividing the standard deviation by n. It is the variance that is divided by n; the standard deviation is divided by √n. For the eggs, 5 ÷ √25 = 1 g, not 5 / 25 = 0.2 g.

Worked example: Eggs from a Farm Weighed One at a Time and Twenty-Five at a Time

Question The masses of eggs from a farm are normally distributed with mean 62 g and standard deviation 5 g. An inspector weighs a random sample of 25 eggs and works out their mean mass, X grams. (a) Find E(X) and Var(X). (b) Using Φ(2) = 0.9772 and Φ(0.4) = 0.6554, find the probability that the mean mass of the sample is less than 60 g, and compare it with the probability that a single egg is less than 60 g.

  1. 1.The mean of the sample has the same expected value as a single egg: E(X) = μ = 62 g.

    6260gmean of 25one egg: sd 5mean of the sample: 62 g
    6260gmean of 25one eggmean of the sample: 62 g
    The mean of 25 eggs is centered on the same 62 g as one egg: E(X) = 62.
  2. 2.(a) Var(X) = σ2n = 5225 = 2525 = 1. So E(X) = 62 and Var(X) = 1, and the standard deviation of the mean is √1 = 1 g.

    6260gmean of 25: sd 1one egg: sd 5Var = 5 × 5/25 = 1sd of the mean: 1 g
    6260gmean of 25: sd 1one eggVar = 5 × 5/25 = 1sd of the mean: 1 g
    (a) Var(X) = 5225 = 1, so the curve for the mean is 5 times as narrow as the curve for one egg.
  3. 3.The masses are normal, so X ∼ N(62, 1). Standardize with the standard deviation of the mean: z = 60 − 621 = −2, so P(X < 60) = 1 − Φ(2) = 1 − 0.9772 = 0.0228.

    6260gmean of 25: sd 1one egg: sd 5z = (60 − 62)/1 = −21 − 0.9772 = 0.0228
    6260gmean of 25: sd 1one eggz = (60 − 62)/1 = −21 − 0.9772 = 0.0228
    The shaded tail of the mean's curve: P(X < 60) = 1 − Φ(2) = 0.0228.
  4. 4.For a single egg the standard deviation is 5 g: z = 60 − 625 = −0.4, so P(X < 60) = 1 − Φ(0.4) = 1 − 0.6554 = 0.3446.

    6260gmean of 25: sd 1one egg: sd 5one egg: z = (60 − 62)/5 = −0.41 − 0.6554 = 0.3446
    6260gmean of 25: sd 1one eggone egg: z = (60 − 62)/5 = −0.41 − 0.6554 = 0.3446
    For one egg, 60 g is only 0.4 standard deviations below the mean: P(X < 60) = 0.3446.
  5. 5.(b) The mean of the sample is below 60 g with probability 0.0228, while a single egg is below 60 g with probability 0.3446, about 15 times as likely. Check: the curve for the mean is 5 times as narrow, so 60 g is 2 of its standard deviations below 62 g, rather than 0.4 of them.

    6260gmean of 25: sd 1one egg: sd 5mean of 25 under 60 g: 0.0228one egg under 60 g: 0.3446
    6260gmean of 25: sd 1one eggmean of 25 under 60 g: 0.0228one egg under 60 g: 0.3446
    (b) The mean of the sample is below 60 g with probability 0.0228, a single egg with probability 0.3446.

Answer: (a) E(X) = 62 g and Var(X) = 1; (b) P(X < 60) = 0.0228, against 0.3446 for a single egg

Common mistakes

  • Standardizing the sample mean with σ = 5 and getting 0.3446. That is the probability for a single egg; the mean of 25 eggs has standard deviation 5√25 = 1 g.
  • Dividing the standard deviation by 25 instead of by √25. It is the variance that is divided by n; the standard deviation is divided by √n = 5.

More sampling problems, worked step by step →

Practice Mean and Variance of X-bar in the app