2. Example-2
2. Non parametric test - Chi square test for the following data 29,24,22,19,21,18,19,20,23,18,20,23, Significance Level `alpha=0.05` and One-tailed test
Solution: Step-1:State the hypothesis `H_0`: observed data and expected data are independent.
`H_1`: observed data and expected data are not independent.
Step-2:Observed Frequencies `29,24,22,19,21,18,19,20,23,18,20,23`
sum`=256` and `n=12`
Step-3: Calculate Expected Frequency value `256/12=21.3333`
Step-4: Chi-square
Id | Observed | Expected | `O_i-E_i` | `(O_i-E_i)^2` | `(O_i-E_i)^2/E_i` | 1 | 29 | 21.3333 | 7.6667 | 58.7778 | 2.7552 | 2 | 24 | 21.3333 | 2.6667 | 7.1111 | 0.3333 | 3 | 22 | 21.3333 | 0.6667 | 0.4444 | 0.0208 | 4 | 19 | 21.3333 | -2.3333 | 5.4444 | 0.2552 | 5 | 21 | 21.3333 | -0.3333 | 0.1111 | 0.0052 | 6 | 18 | 21.3333 | -3.3333 | 11.1111 | 0.5208 | 7 | 19 | 21.3333 | -2.3333 | 5.4444 | 0.2552 | 8 | 20 | 21.3333 | -1.3333 | 1.7778 | 0.0833 | 9 | 23 | 21.3333 | 1.6667 | 2.7778 | 0.1302 | 10 | 18 | 21.3333 | -3.3333 | 11.1111 | 0.5208 | 11 | 20 | 21.3333 | -1.3333 | 1.7778 | 0.0833 | 12 | 23 | 21.3333 | 1.6667 | 2.7778 | 0.1302 | | 256 | | | | 5.0938 |
`chi^2=sum (O_i-E_i)^2/(E_i)=5.0938`
Step-5: Compute the degrees of freedom (df). `df=12-1=11`
Step-6: for 11 df, `p(chi^2>=5.0938)=0.9265`
Since the p-value(0.9265) > `alpha(0.05)` (one-tailed test), we can't reject the null hypothesis `H_0`.
This material is intended as a summary. Use your textbook for detail explanation. Any bug, improvement, feedback then
|