2 The sign test
The sign test is used to test hypotheses concerning the median of a continuous distribution. Some authors use the symbol to represent to median of the distribution - remember that is used to represent the mean of a distribution. We will use the notation for the median throughout this Workbook. Remember that in the case of a normal distribution the mean is equal to the median and so the sign test can be used to test hypotheses concerning the mean of a normal distribution. The test procedure is straightforward to describe. The usual null hypothesis is
As you might expect, the alternative hypothesis can take one of three forms
Now suppose the sample taken from a population is . We form the differences
Assuming that the null hypothesis is true, each difference is equally likely to be positive or negative and in order to test a particular pair of hypotheses we need only test the number of plus signs (say). Under the null hypothesis this is a value of the binomial distribution with parameter . In order to decide whether we should reject a null hypothesis, we can calculate probabilities directly from the binomial distribution (see HELM booklet 37) using the formula
or by using the normal approximation to the binomial distribution.
The following Examples and Tasks illustrate the test procedure.
Example 1
The compressive strength of insulating blocks used in the construction of new houses is tested by a civil engineer.
The engineer needs to be certain at the 5% level of significance that the median compressive strength is at least 1000 psi. Twenty randomly selected blocks give the following results:
Observation | Compressive Strength | Observation | Compressive Strength | Observation | Compressive Strength | Observation | Compressive Strength |
1 | 1128.7 | 6 | 718.4 | 11 | 1167.1 | 16 | 1153.6 |
2 | 679.1 | 7 | 787.4 | 12 | 1387.5 | 17 | 1423.3 |
3 | 1317.2 | 8 | 1562.3 | 13 | 679.9 | 18 | 1122.6 |
4 | 1001.3 | 9 | 1356.9 | 14 | 1323.2 | 19 | 1644.3 |
5 | 1107.6 | 10 | 1153.2 | 15 | 788.4 | 20 | 737.4 |
Test (at the 5% level of significance) the null hypothesis that the median compressive strength of the insulting blocks is 1000 psi against the alternative that it is greater.
Solution
The hypotheses are
Comp. Strength | Sign | Comp. Strength | Sign | Comp. Strength | Sign | Comp. Strength | Sign |
1128.7 | 718.4 | 1167.1 | 1153.6 | ||||
679.1 | 787.4 | 1387.5 | 1423.3 | ||||
1317.2 | 1562.3 | 679.9 | 1122.6 | ||||
1001.3 | 1356.9 | 1323.2 | 1644.3 | ||||
1107.6 | 1153.2 | 788.4 | 737.4 | ||||
We have 14 plus signs and the required probability value is calculated directly from the binomial formula as
Since we are performing a one-tailed test, we must compare the calculated value with the value 0.05.
Since we conclude that we cannot reject the null hypothesis and that on the basis of the available evidence, we cannot conclude that the median compressive strength of the insulating blocks is greater than 1000 psi.
Example 2
A certain type of solid rocket fuel is manufactured by bonding an igniter with a propellant. In order that the fuel burns smoothly and does not suffer either “flame-out” or become unstable it is essential that the material bonding the two components of the fuel has a shear strength of 2000 psi. The results arising from tests performed on 20 randomly selected samples of fuel are as follows:
Observation | Shear Strength | Observation | Shear Strength | Observation | Shear Strength | Observation | Shear Strength |
1 | 2128.7 | 6 | 1718.4 | 11 | 2167.1 | 16 | 2153.6 |
2 | 1679.1 | 7 | 1787.4 | 12 | 2387.5 | 17 | 2423.3 |
3 | 2317.2 | 8 | 2562.3 | 13 | 1679.9 | 18 | 2122.6 |
4 | 2001.3 | 9 | 2356.9 | 14 | 2323.2 | 19 | 2644.3 |
5 | 2107.6 | 10 | 2153.2 | 15 | 1788.4 | 20 | 1737.4 |
Using the 5% level of significance, test the null hypothesis that the median shear strength is 2000 psi.
Solution
The hypotheses are
We determine the signs associated with each observation as shown below and perform a two-tailed test.
Shear Strength | Sign | Shear Strength | Sign | Shear Strength | Sign | Shear Strength | Sign |
2128.7 | 1718.4 | 2167.1 | + | 2153.6 | |||
1679.1 | 1787.4 | 2387.5 | + | 2423.3 | + | ||
2317.2 | 2562.3 | 1679.9 | 2122.6 | + | |||
2001.3 | 2356.9 | 2323.2 | + | 2644.3 | + | ||
2107.6 | 2153.2 | 1788.4 | 1737.4 | ||||
We have 14 plus signs and the required probability value is calculated directly from the binomial formula:
Since we are performing a two-tailed test, we must compare the calculated value with 0.025.
Since we cannot reject the null hypothesis on the basis of the evidence and conclude that the median shear strength is not significantly different from 2000 psi. Now do the following Task.
Task!
A certain type of solid rocket fuel is manufactured by binding an igniter with a propellant. In order that the fuel burns smoothly and does not suffer either “flame-out” or become unstable it is essential that the material bonding the two components of the fuel has a shear strength of 2000 psi. The results arising from tests performed on 10 randomly selected samples of fuel are as follows.
Observation | Shear Strength | Observation | Shear Strength |
1 | 2128.7 | 6 | 1718.4 |
2 | 1679.1 | 7 | 1787.4 |
3 | 2317.2 | 8 | 2562.3 |
4 | 2001.3 | 9 | 2356.9 |
5 | 2107.6 | 10 | 2153.2 |
Using the 5% level of significance, test the null hypothesis that the median shear strength is 2000 psi.
The hypotheses are
We determine the signs associated with each observation as shown below and perform a two-tailed test.
Shear Strength | Sign | Shear Strength | Sign |
2128.7 | 1718.4 | ||
1679.1 | 1787.4 | ||
2317.2 | 2562.3 | ||
2001.3 | 2356.9 | ||
2107.6 | 2153.2 | ||
We have 7 plus signs and the required probability value is calculated directly from the binomial formula as
Since we are performing a two-tailed test, we must compare the calculate value with the value 0.025. Since we cannot reject the null hypothesis on the basis of the available evidence and we cannot conclude that the median shear strength is different to 2000 psi.