Computing the Chi Square Test of Independence (1 of 5)
The first step in computing the chi square test of independence is to
compute the expected frequency for each cell under the assumption
that the
null hypothesis is true.
To calculate the expected frequency of the first cell in the
example (experimental condition,
graduated), first calculate the proportion of subjects that graduated
without considering the condition they were in. The table below shows that
of the 167 subjects in the experiment, 116 graduated.
|
Graduated |
Failed to
Graduate |
Total |
Experimental |
73
|
12
|
85 |
Control |
43
|
39
|
82 |
Total |
116 |
51 |
167 |
Therefore,
116/167 graduated. If the null hypothesis were true, the expected
frequency for the first cell would equal the product of the number of
people in the experimental condition (85) and the proportion of
people graduating (116/167). This is equal to (85)(116)/167 = 59.042.
Therefore, the expected frequency for this cell is 59.042. The
general formula for expected cell frequencies is:
where E
ij is the expected frequency for the cell in the
ith row and the jth column, T
i is the total number of
subjects in the ith row, T
j is the total number of
subjects in the jth column, and N is the total number of subjects in
the whole table.