2. Non parametric test - Median test for the following data
12,14,15,12,7,4,10,4,4,4,5,10
Median = 10, Significance Level `alpha=0.05` and One-tailed test
Solution:
Step-1:State the hypothesis
`H_0`: population median `>=` 10.
`H_1`: population median `<` 10.
Step-2: To perform the test, we count number of elements > 10 and number of elements < 10. We drop elements with value exactly 10.
In 3rd column, we put +1 if element is > 10, -1 if element is < 10 and 0 if element is = 10.
# | A | Sign |
1 | 12 | 1 |
2 | 14 | 1 |
3 | 15 | 1 |
4 | 12 | 1 |
5 | 7 | -1 |
6 | 4 | -1 |
7 | 10 | 0 |
8 | 4 | -1 |
9 | 4 | -1 |
10 | 4 | -1 |
11 | 5 | -1 |
12 | 10 | 0 |
So Obtained frequency (`of`) for each category
Number of plus sign = 4
Number of minus sign = 6
N = 4 + 6 = 10 (because zero is in some observations)
Step-3: The expected frequency of each cell is `1/2` of the number of cases
`ef = 1/2 xx N = 1/2 xx 10 = 5`
Step-4: Compute Chi-square
`chi^2= sum (of-ef)^2/(ef)`
`=(4-5)^2/(5)+(6-5)^2/(5)`
`=0.2+0.2`
`=0.4`
Step-5: Compute the degrees of freedom (df).
`df=1`
Step-6:
The Critical value of chi-square is `chi^2(0.05,1)=3.8415`
Step-7:
Since the computed `chi^2`(0.4) < critical `chi^2`(3.8415)
So we accept the null hypothesis (`H_0`).
This material is intended as a summary. Use your textbook for detail explanation.
Any bug, improvement, feedback then