In: Statistics and Probability
Below is table of observed count data that you would like to use to run a Chi Square Test of Independence. Based on data presented would you violate any assumptions? How do you know?
Condition 1 |
Condition 2 |
|
Condition A |
24 |
5 |
Condition B |
6 |
7 |
Step-: State the hypothesis:
H0: Two categories
variables are independent.
H1: Two categories variables are not independent.
Step-2:
Observed
Frequencies:
Condition 1 |
Condition 2 |
Total |
|
Condition A1 |
24 |
5 |
29 |
Condition A2 |
6 |
7 |
13 |
Total |
30 |
12 |
42 |
Step-3:Expected Frequencies:
Fe11 = (29 x 30 ) / 42 = 20.7143
Fe12 = (29 x 12 ) / 42 = 8.2857
Fe21 = ( 13 x 30 ) / 42 = 9.2857
Fe22 = ( 13 x 12 ) / 42 = 3.7143
Condition 1 |
Condition 2 |
Total |
|
Condition A1 |
20.7143 |
8.2857 |
29 |
Condition A2 |
9.2857 |
3.7143 |
13 |
Total |
30 |
12 |
42 |
Step-4: Compute Chi-square:
χ2 = ∑ [ (Oi - Ei)² / Ei ]
= (24 -
20.7143)²
/ 20.7143 + (5 -
8.2857)²
/ 8.2857 + (6 -
9.2857)²
/ 9.2857 + (7 -
3.7143)²
/ 3.7143
= 0.5212 + 1.303 + 1.1626 + 2.9066
= 5.8934
χ2 = 5.8934 -------------------------(Calculated value)
Step-5: Compute the degrees of freedom
(df):
df= (2 -
1)⋅(5 - 1)
df = 4
Level of significance = 0.05
χ2 = 3.841 -------------------------(Tabulated value)
Step-6: Decision:
Calculated value > Tabulated value
5.8934 > 3.841
P value = 1 – (0.05/2)
= 1 – 0.025
P value = 0.975
Critical value = 1.96
Step-7: Conclusion:
Null hypothesis is rejected.
Alternative hypothesis is accepted.
H1: Two categories variables are not independent.