Test statistic and p-value
The statistical distance of an estimate to a hypothesised value of the underlying parameter is
If the null hypothesis holds, z has approximately a standard normal distribution and it can be used as a test statistic for tests about the parameter. The p-value can be determined from the tail areas of this standard normal distribution.
For a two-tailed test, the p-value is the red tail area and can be looked up using either normal tables or in Excel.
Example
We again examine a data set in which a proportion 37/2500 = 0.0148 of 2,500 patients had adverse reactions to a drug. Do more than 1% of such patients have adverse reactions?
H0 : π = 0.01
HA : π > 0.01
The diagram below shows how the 'statistical distance' of the sample proportion from 0.01 is calculated.
The p-value for the test is the upper tail area of the standard normal distribution and is 0.0079 here, so we again conclude that there is strong evidence that more than 1% of patients have adverse reactions from the drug.
Using a 'statistical distance' to test a proportion gives a p-value that is identical to the p-value based on a normal approximation to the number of successes without a continuity correction. (The p-value is slightly different if a continuity correction is used.) However this approach will be used to test many different kinds of parameter in later sections.
(The procedure will be refined slightly when applied to situations where the standard error of the estimate must itself be estimated from the sample data. A t distribution will be used instead of a standard normal distribution.)