2. Example-2
1. Non parametric test - Mood's Median test for the following data 11,15,9,4,34,17,18,14,12,13,26,31 34,31,35,29,28,12,18,30,14,22,10,29, Significance Level `alpha=0.05` and One-tailed test
Solution:
A | B | 11 | 34 | 15 | 31 | 9 | 35 | 4 | 29 | 34 | 28 | 17 | 12 | 18 | 18 | 14 | 30 | 12 | 14 | 13 | 22 | 26 | 10 | 31 | 29 |
Step-1:Calculate total Median of combination of 2 samples Sorting of cobmined samples `4,9,10,11,12,12,13,14,14,15,17,18,18,22,26,28,29,29,30,31,31,34,34,35`
`n=24`
Median `= (12^(th) "term" + 13^(th) "term" )/2=(18 + 18)/2= 18`
Step-2:Create a `2 xx 2` contingency table whose first row consists of the number of elements in each sample that are greater than Median and second row consists of the number of elements in each sample that are less than or equal to Median
| Sample A | Sample B | Total | `>` Median | 3 | 8 | 11 | `<=` Median | 9 | 4 | 13 | Total | 12 | 12 | 24 |
Step-3:Perform a chi-square test of independence
Step-1:State the hypothesis `H_0`: two categories variables are independent.
`H_1`: two categories variables are not independent.
Step-2:Observed Frequencies
| `B_1` | `B_2` | Total | `A_1` | 3 | 8 | 11 | `A_2` | 9 | 4 | 13 | Total | 12 | 12 | 24 |
Step-3:Expected Frequencies Steps `E_(1,1)=(3-5.5)^2/5.5=1.1364`
`E_(1,2)=(8-5.5)^2/5.5=1.1364`
`E_(2,1)=(9-6.5)^2/6.5=0.9615`
`E_(2,2)=(4-6.5)^2/6.5=0.9615`
Step-3:Expected Frequencies
| `B_1` | `B_2` | Total | `A_1` | 5.5 | 5.5 | 11 | `A_2` | 6.5 | 6.5 | 13 | Total | 12 | 12 | 24 |
Step-4: Compute Chi-square `chi^2=sum (O_(ij)-E_(ij))^2/(E_(ij))`
`=(3-5.5)^2/5.5+(8-5.5)^2/5.5+(9-6.5)^2/6.5+(4-6.5)^2/6.5`
`=6.25/5.5+6.25/5.5+6.25/6.5+6.25/6.5`
`=1.1364+1.1364+0.9615+0.9615`
`=4.1958`
Step-5: Compute the degrees of freedom (df). `df=(2-1)*(2-1)=1`
Step-6:for 1 df, `p(chi^2>=4.1958)=0.0405`
Since the p-value(0.0405) < `alpha(0.05)` (one-tailed test), we reject the null hypothesis `H_0`.
This material is intended as a summary. Use your textbook for detail explanation. Any bug, improvement, feedback then
|