We want to measure how far a sample average xˉ lands from the true population average μ, even when we don't know the true spread σ of the population.
1
Standard Error: Our Ruler When σ Is Unknown
To tell whether a sample average xˉ landed close to the true center μ or far out in the tails, we need a ruler that measures how big a typical step is on the number line.
When we know the true spread σ across the whole population, averaging n items together partly cancels out high and low extremes, so sample averages vary by the smaller step size nσ:
z=nσxˉ−μ
In practice, if we are taking a sample because we don't know the population average μ, we usually won't know the population spread σ either. We have to build our ruler from the sample we actually have.
Standard Error: Our Ruler When Sigma Is Unknown
Swapping the unknown population spread σ for the spread s measured in our sample gives our new step size on the number line:
Old ruler: nσ⟶New ruler: standard error of the meanns
2
The Rubber Ruler and Student's t-Distribution
Now that our ruler ns is built from the sample, we want to see how many rulers away from μ our sample averages land, and why the Normal bell curve no longer catches 95% of small samples within 1.96 steps.
The Rubber Ruler and Student's t-Distribution
Measuring the gap between a sample average xˉ and the center μ in standard error steps gives a t-score:
t=standard errornsxˉ−μ
With the steel ruler nσ, only the sample average xˉ on top changes from sample to sample. With the rubber ruler ns, the bottom of the fraction changes every time too, and whenever it shrinks, it pushes scores that would have stayed near the middle out into the tails.
Normal
Student’s t
95%
−t∗
−1.96
0
+1.96
+t∗
Even when a sample average xˉ lands fairly close to μ, if the 4 sample laptops happen to cluster tightly together, the rubber ruler ns shrinks. More of those tiny steps fit across the gap, pushing the t-score far out into the tail.
Even when the sample average stays in the same spot near the true mean, tightly clustered sample points shrink the rubber ruler and fit more steps across the gap.
3
Sample Size and Degrees of Freedom
Because the t-distribution is a family of curves that get narrower as the sample grows, we need a way to pick the exact t-curve that matches our sample size n.
Sample Size and Degrees of Freedom
ns
n=?
Normal
Student’s t
−4−3−2−101234
A single data point (n=1) only gives us a sample average xˉ and tells us nothing about spread. Only the remaining n−1 points can vary around that average to show how spread out the data is, so the reliability of our ruler depends on n−1:
degrees of freedomdf=n−1
Here df stands for degrees of freedom, the number that picks the right t-curve for a sample of size n.
As the sample size grows from n=2 to n=50, the degrees of freedom df=n−1 go up, the rubber ruler ns settles closer to the true steel ruler nσ, and the fat-tailed t-curve pulls inward toward the Normal curve so the 95% cutoffs ±t∗ slide in toward ±1.96.
As your sample grows, each new laptop after the first adds one more degree of freedom, stiffening the rubber standard-error ruler like steel and pulling the t-curve in toward the Normal curve.
4
Finding the Cutoff t∗ for a Confidence Level
To build a confidence interval around xˉ when σ is unknown, we need the cutoff t∗: the number of standard error steps we reach to the left and right of xˉ to capture the middle percentage of the t-curve. (The ∗ marks the cutoff step count for a chosen confidence level, rather than the t-score of a sample.)
When σ was known, a 95% confidence interval started at xˉ and reached z∗=1.96 steel rulers (nσ) each way. With our rubber ruler ns, we replace z∗ with the wider multiplier t∗ from the df=n−1 curve.
Suppose a company claims its laptop batteries last μ=12 hours. You test n=9 laptops and find a sample average of xˉ=10.5 hours with a sample spread of s=1.8 hours. How far to the left and right of 10.5 hours do we reach for 95% confidence?
Finding the Cutoff t* for a Confidence Level
μ=12 hours
n=9
xˉ=10.5 hourss=1.8 hours
t∗ for 95% confidence=?
Text solution
Find the standard error and degrees of freedomDivide the sample spread s=1.8 hours by 9 to get the size of one step on the number line, and subtract 1 from the sample size n=9 to pick the curve:
Standard error=ns=91.8=31.8=0.6 hours
df=n−1=9−1=8
Split the leftover area into the two tailsCapturing the middle 95% (0.95) of the symmetric df=8 curve leaves 5% (0.05) outside, split evenly into 2.5% (0.025) in each tail:
0.95
0.025
0.025
−t∗
0
+t∗
0.95+0.025=0.975
One-tail area=21−0.95=20.05=0.025
Find the cutoff t∗ on the df=8 curve Match the 0.025 one-tail column (or 95% confidence label) with row df=8 on a printed t-table, or enter the total area to the left of +t∗ (0.95+0.025=0.975) into a calculator:
invT(area=0.975,df=8)=2.306
Multiply the standard error by t∗ Multiply the 0.6-hour standard error by t∗=2.306 steps to find how far to reach in hours:
Reach=t∗×Standard error=2.306×0.6≈1.38 hours
So to catch the true average with 95% confidence, we start at our sample average of 10.5 hours and reach ±1.38 hours to the left and right.
After df=30, printed t-tables skip rows (jumping from 60 to 80 to 100). If you test n=75 laptops so df=74, go down to df=60 rather than rounding up to 80, so you never pretend you have a larger sample than you actually do.
5
Finding a t-Score and Its Tail Area
Now let's flip the question around: when we want to test a claimed center μ, we find how many standard error steps away our sample average xˉ landed (t) and find the tail area beyond it to see how unusual our sample is.
For the same n=9 laptops with xˉ=10.5 hours, standard error 0.6 hours, and df=8, how unusual is it to get a sample average of 10.5 hours or lower if the true average really is μ=12 hours?
Finding a t-Score and Its Tail Area
n=9μ=12 hoursxˉ=10.5 hours
Standard error=0.6 hoursdf=8
t=?
−4−3−2−101234
Text solution
Measure the gap in standard error stepsSubtract the claimed center μ=12 from our sample average xˉ=10.5 and divide by our 0.6-hour standard error ruler:
t=nsxˉ−μ=0.610.5−12=0.6−1.5=−2.5
Find the exact left-tail area using a calculatorFind the area under the df=8 curve from −∞ up to our sample's score of t=−2.5:
Tail area=tcdf(−∞,−2.5,8)≈0.0185=1.85%
Place the tail area between two values on a printed t-tableBy symmetry, the left tail below −2.5 matches the right tail above +2.5, which sits between 2.306 (one-tail area 0.025) and 2.896 (one-tail area 0.01) on the df=8 row:
≈0.0185
≈0.0185
−2.5
0
+2.5
0.025
2.306
0.01
2.896
+2.5
⟹2.306<2.5<2.8960.01<Tail area<0.025
So if the true average battery life were 12 hours, only about 1.85% of 9-laptop samples (between 1% and 2.5%) would land 2.5 standard errors or further below the center by chance.
Key concepts
The choice between the Normal z-curve and Student's t-distribution comes down to one question: where did the spread come from? If you know the true spread σ of the entire population (such as knowing σ=1.8 hours across the whole factory), your ruler nσ is fixed steel and you stay on the Normal curve (z∗=1.96 for 95%). Whenever σ is unknown and you measure the spread s from your sample of n items (such as n=9 laptops with s=1.8 hours), your ruler is the rubber standard error of the mean,
Standard error=ns=91.8=0.6 hours
and you work on the t-curve with df=n−1=8 degrees of freedom.
On that df=n−1 curve, we move in two directions:
Percentage ⟶ step cutoff t∗ (for a confidence interval)
Split the outside area in half to look up the one-tail column on row df=n−1 (going down to the next smaller df row if yours isn't listed), or enter the middle area plus one lower tail into `invT`. For the middle 95% with df=8,invT(area=0.975,df=8)=2.306, which reaches ±2.306×0.6≈±1.38 hours around xˉ.
Sample average xˉ⟶t-score and tail area (to test a center μ)
Divide the gap from μ by the standard error,
t=nsxˉ−μ=0.610.5−12=−2.5
then find the area beyond t with tcdf(−∞,−2.5,8)≈0.0185, or drop the minus sign and place 2.5 between 2.306 (0.025) and 2.896 (0.01) along the df=8 row to see the tail area sits between 1% and 2.5%.
6
Practice
1
A coffee machine claims to dispense an average of μ=8 oz per cup. You test a sample of n=16 cups and find a sample average of xˉ=7.7 oz with a sample standard deviation of s=0.6 oz. Find (a) the standard error of the mean, (b) the degrees of freedom, and (c) the t-score of your sample.
Be careful not to divide by 16 without taking the square root, which would give 0.0375 oz.
How does averaging n=16 cups together shrink the individual cup spread s=0.6 oz to give your ruler?
(a) Divide the sample spread s by n (be careful not to divide by 16 without taking the square root, which would give 0.0375 oz):
Standard error=ns=160.6=40.6=0.15 oz
(b) Subtract 1 from the sample size n=16:
df=n−1=16−1=15
(c) Divide the gap xˉ−μ by the 0.15-oz standard error ruler (not by the single-cup spread s=0.6 oz, which would give t=−0.5):
t=nsxˉ−μ=0.157.7−8=0.15−0.3=−2.0
2
You test n=25 car batteries and find a sample average life of xˉ=48 months with a sample spread of s=5 months. You want to build an interval for the middle 90% of the curve. (a) What total area to the left and what degrees of freedom do you enter into an `invT` command to find the upper cutoff t∗? (b) Using t∗=1.711, how many months to the left and right of 48 months do you reach?
Don't enter area=0.90 alone, which leaves 10% in the upper tail and gives the 80% cutoff 1.318.
Sketch the curve with 90% in the middle: how much leftover area sits in the lower tail to the left of that middle 90%?
(a) Leaving 90% in the middle puts 10% outside, or 5% (0.05) in each tail. Add the lower tail 0.05 to the middle 0.90 (don't enter area=0.90 alone, which leaves 10% in the upper tail and gives the 80% cutoff 1.318), and use df=25−1=24:
Area to the left=0.90+0.05=0.95
invT(area=0.95,df=24)
(b) First find the standard error ruler ns=255=1 month (don't multiply t∗ by the single-battery spread s=5 months, which would give ±8.555 months), then multiply by ±t∗:
You test n=90 lightbulbs and want the 95% confidence cutoff t∗ from a printed t-table whose rows jump from df=60 (t∗=2.000) to df=80 (t∗=1.990) to df=100 (t∗=1.984). Which t∗ value should you use, and why?
After finding df=n−1, which neighboring row on the table avoids pretending you tested more lightbulbs than you actually did?
With n=90, your degrees of freedom is df=90−1=89. Because 89 is not on the table, go down to df=80 so you do not pretend you tested more lightbulbs than you actually did (don't round up to df=100, which would claim 100 degrees of freedom and give a too-narrow cutoff of 1.984). From the df=80 row, use t∗=1.990.
4
A cereal maker claims boxes contain μ=500 g on average. A sample of n=9 boxes has xˉ=494 g and s=6 g. On the df=8 row of a printed t-table, the cutoffs for one-tail areas of 0.05,0.025,0.01, and 0.005 are 1.860,2.306,2.896, and 3.355. Between what two percentages does the tail area below your sample average fall?
Find how many standard errors 494 g sits below 500 g, then use symmetry to place that step count between two cutoffs on the df=8 row.
First find the standard error ns=96=2 g and divide the gap by 2 g (dividing by s=6 g instead of the standard error would give t=−1.0, making the tail area look larger than 5%):
t=96494−500=2−6=−3.0
By symmetry on the df=9−1=8 curve, the left tail below −3.0 equals the right tail above +3.0. Since 3.0 sits between 2.896 (one-tail area 0.01) and 3.355 (one-tail area 0.005), the tail area falls between 0.5% and 1%.
5
Two testers each test n=4 laptops from a factory where the true mean battery life is μ=12 hours. Tester A gets xˉ=10.5 hours and s=2.0 hours. Tester B gets four laptops that happen to cluster tightly together, with xˉ=11.6 hours and s=0.2 hours. Whose sample average is closer to the true mean, whose sample produces the more extreme t-score, and why?
Compare the distance xˉ−μ in hours for each tester, then compare the size of each tester's rubber ruler 4s.
Tester B's sample average (11.6 hours) is closer to the true mean of 12 hours than Tester A's (10.5 hours). However, don't assume Tester A has the more extreme t-score just because a 1.5-hour gap is wider than a 0.4-hour gap: because Tester B's 4 laptops clustered tightly together, Tester B's rubber ruler shrank to 40.2=0.1 hours, making the small 0.4-hour gap measure 4 steps wide: