In most practical situations where normal distributions are used as models for data, the normal variance, \(\sigma^2\), is an unknown parameter. The test statistic on the previous page,

\[ Z \;\;=\;\; \frac{\overline{X} - \mu_0}{\diagfrac {\sigma}{\sqrt n}} \]

can no longer be evaluated in a test for \(\mu\) since \(\sigma^2\) is now unknown.

Test statistic

If \(\sigma\) is replaced by the sample standard deviation, \(S\), the test statistic

\[ T \;\;=\;\; \frac{\overline{X} - \mu_0}{\diagfrac {S}{\sqrt n}} \]

no longer has a standard normal distribution, but its distribution is another standard distribution when H0 is true.

Distribution of test statistic T

If \(\overline{X}\) and \(S^2\) are the mean and variance of a random sample of size \(n\) from a \(\NormalDistn(\mu_0, \sigma^2)\) distribution,

\[ T \;\;=\;\; \frac{\overline{X} - \mu_0}{\diagfrac{S}{\sqrt{n}}} \;\;\sim\;\; \TDistn(n-1 \text{ df}) \]

(Proved in full version)

T-test for \(\mu\)

The test statistic \(T\) is used in a similar way to the \(Z\) statistic on the previous page, but the p-value is obtained as a tail probability from a t distribution instead of a standard normal one.