You are viewing a free preview of this lesson.
Subscribe to unlock all 10 lessons in this course and every other course on LearningBro.
A contingency table (also called a two-way table) displays the frequency distribution of two categorical variables. The chi-squared test of association determines whether the two variables are independent.
An r×c contingency table has r rows and c columns:
| Column 1 | Column 2 | ⋯ | Column c | Row Total | |
|---|---|---|---|---|---|
| Row 1 | O11 | O12 | ⋯ | O1c | R1 |
| Row 2 | O21 | O22 | ⋯ | O2c | R2 |
| ⋮ | ⋮ | ⋮ | ⋮ | ⋮ | |
| Row r | Or1 | Or2 | ⋯ | Orc | Rr |
| Col Total | C1 | C2 | ⋯ | Cc | N |
where N is the grand total.
H0: There is no association between the two variables (they are independent).
H1: There is an association between the two variables (they are not independent).
Under H0 (independence), the expected frequency for cell (i,j) is:
Eij=NRi×Cj
Subscribe to continue reading
Get full access to this lesson and all 10 lessons in this course.