Open two statistics textbooks and you may find the same table analyzed under two different names: a chi-square test of independence in one, a chi-square test of homogeneity in the other. The arithmetic is identical. The degrees of freedom match, the p-value matches, and software cannot tell them apart. What differs is how the data were collected, and that changes what you are allowed to say.
A test of independence starts with one sample. You take 200 students and classify each on two variables, say major (STEM or non-STEM) and preferred study mode (alone, in a group, or mixed). The question is whether the two variables are related in that population: knowing a student's major, does it tell you anything about how they prefer to study? The null hypothesis is that the two variables are independent.
A test of homogeneity starts with separate samples from separate populations. You draw 100 students from a STEM program and 100 from a non-STEM program, then record study mode for each. The row totals were fixed by your design, not discovered. The question is whether the distribution of study mode is the same in both populations. The null hypothesis is that it is.
Suppose both studies produce this table, with STEM first and non-STEM second: alone 40 and 25, in a group 30 and 45, mixed 30 and 30. The expected count in each cell under the null hypothesis is the row total times the column total over the grand total, so the STEM row expects 32.5, 37.5 and 30. Add up the squared gaps between observed and expected, each divided by expected, and you get a chi-square of 6.46 on 2 degrees of freedom, which gives p = .040. That result is the same under both names. Only the sentence you write about it changes.
The usual rule is that expected counts should be about 5 or more in most cells. With small expected counts, the chi-square approximation is poor, and an exact test such as Fisher's exact test is a better choice for a 2 by 2 table. Observations must be independent, which fails if the same person appears more than once or if participants come in clusters like classrooms. And a significant result in a large sample can be trivially small, so report an effect size. For this table, Cramér's V is about .18, a small association.
Give the test, the degrees of freedom, the sample size, the statistic, the exact p-value and an effect size, and say what the result means. For the single-sample version: "A chi-square test of independence showed a small association between major and study mode, χ²(2, N = 200) = 6.46, p = .040, V = .18." For the two-sample version: "The distribution of study mode differed between STEM and non-STEM students, χ²(2, N = 200) = 6.46, p = .040, V = .18." Report the table of counts or percentages alongside it. Our free chi-square APA formatter builds the sentence and table for you.
If you are not sure which design your data came from, or the expected counts are small and you are deciding between tests, send us a description of how the data were collected. It is usually a short conversation.
One email whenever we publish something new. No spam, unsubscribe anytime.
{{ subscribeErrorMsg }}