Chapter 3
Chapter 3
HYPOTHESIS TESTS
Statistical Hypotheses
Examples:
• cents, where is the true population average of daily per-student candy ,soda expenses in US
high schools
• where is the population proportion of defective helmets for a given manufacturer
• If denote the true average breaking strengths of two different types of twine, one
hypothesis might be the assertion that , or another is the statement 5
Components of a Hypothesis Test
1. Formulate the hypothesis to be tested.
2. Determine the appropriate test statistic and calculate it using the sample data.
3. Comparison of test statistic to critical region to draw initial conclusions.
4. Calculation of p-value.
5. Conclusion, written in terms of the original problem.
1. Formulate the hypothesis to be tested.
Example : Suppose a company is considering putting a new type of coating on bearings that
it produces.
The true average wear life with the current coating is known to be 1000 hours. With
denoting the true average life for the new coating, the company would not want to make any
(costly) changes unless evidence strongly suggested that exceeds 1000
An appropriate problem formulation would involve testing
against
The conclusion that a change is justified is identified with , and it would take conclusive
evidence to justify rejecting and switching to the new coating. Scientific research often
involves trying to decide whether a current theory should be replaced, or “elaborated
upon.”
The alternative to the null hypothesis will look like one of the following three assertions:
Where
-hypothesized
population mean
Example 3.2
Each year trainees throughout the country sit a test. Over a period of time it has been
established that the marks can be modelled by a normal distribution with mean 70 and
standard deviation 6.
This year it was thought that trainees from a particular county did not perform as well as
expected. The marks of a random sample of 25 trainees from the county were scrutinised
and it was found that their mean mark was 67.3.
Does this provide evidence, at the 5% significance level, that trainees from this county did
not perform well as expected?
Example 3.3
A sample of size 16 is taken from the distribution of and a hypothesis test is carried out at
the level of significance. On the basis of the value of the sample mean , the null hypothesis
is rejected in favour of the alternative hypothesis . What can be said about the value of ?
Test lb:
Since the population is not normal, you cannot say that the distribution of X is normal for all
sample sizes. If the sample size is large, however, you can apply the central limit theorem.
This states that for large samples taken from a non-normal population, the sampling
distribution of means is approximately normal, whatever the distribution of the parent
population.
The test statistic is , where
Example 3.3
The management of a large hospital states that the mean age of its patients is 45 years.
Records of a random sample of 100 patients give a mean age of 48.4 years. Using a
population standard deviation of 18 years, test at the 5% significance level whether there is
evidence that the management's statement is incorrect. State clearly your null and alternative
hypotheses.
Test lc:
Testing the mean , of a population X where the variance is unknown and the sample size
is large
When calculating confidence intervals it is often the case that the population variance, , is
not known. Provided that the sample size, is large, ( say) it is permissible to use .
Where , is the sample variance.
Or
Ideally the population distribution should be normal, but if it is not, then the central limit
theorem can be applied, since the sample size is large.
The test statistic is , where
Example 3.4
The packaging on an electric light bulb states that the average length of life of bulbs is 1000
hours. A consumer association thinks that this is an over estimate and tests a random sample
of 64 bulbs, recording the life x hours, of each bulb. The results are summarised as follows:
(a) Calculate the sample mean,
(b) Calculate an unbiased estimate for the standard deviation of the length of life of all light
bulbs of this type.
(c) Is there evidence, at the 10% significance level, that the statement on the packaging is
over estimating the length of life of this type of light bulb?
2. Errors in Hypothesis Testing
Definition
• A type I error is when the null hypothesis is rejected, but it is true.
• A type II error is not rejecting when is false.
A Type I error is made if is rejected when is true.
This is written
is rejected| is true)
is accepted| is False)
To calculate the probability of a Type II error, a particular value must be specified in the
alternative hypothesis .
Power of a Test=P(reject when is true)
=
Example 3.5
A random variable has a normal distribution with mean and standard deviation 3. The null
hypothesis is to be tested against the alternative hypothesis using a random sample of size 25.
It is detected that the null hypothesis will be rejected if the sample mean greater than 21.4.
(a) Calculate the probability of making a Type I error.
(b) Calculate the probability of making a Type II error, when in fact .
Test ld:
Testing the mean . when the population X is normal but the variance is unknown and the
sample size is small In this case, the population is normal, so Since is unknown, is used
instead (as in Test 1c). Consider the distribution of the sample mean . When the sample
size is small, does not follow a normal distribution. The standardised statistic is called
and it follows a t-distribution with (n - 1) degrees of freedom.
The test statistic and
Example 3.6
Five readings of the resistance X, in ohms, of a piece of wire gave the following results:
1.51, 1.49, 1.54, 1.52, 1.54
These are summarised by .
If the wire is pure, the resistance is 1.50 ohms. If the wire is impure, its resistance is higher
than 1.50 ohms. Assuming that the resistance can be modelled by a normal variable with
1nean ., and standard deviation , calculate
(a) the sample mean, x,
(b) an unbiased estimate of ,
(c) Is there evidence, at the 5% level of significance, that the wire is impure?
Hypothesis Test 3: Testing ,, The Difference Between Means Of Two Normal
Populations
This test is used when you have two normal populations with unknown means, , and you
want to test the difference between the means of these populations. Consider .
The hypotheses might be:
Test 3a: The population variances and are known