Pearson's Chi-square Test of Independence
Chi-square goodness-of-fit test · Also known as: chi-squared test, χ² test, Ki-Kare Testi, chi-square test
The chi-square test of independence is a nonparametric hypothesis test that determines whether two categorical variables are statistically associated or independent of one another. Introduced by Karl Pearson in 1900, it remains the standard procedure for analysing contingency tables and requires no assumption of normality — only that observations are independent and that expected cell frequencies are sufficiently large.
Read the full method
Sign in with a free account to read this section.
Method map
The neighbourhood of related methods — select a node to explore.
When to use it
Use the chi-square test when you want to assess the association between two categorical variables measured on independent observations. All three assumptions must hold: observations are independent (each participant appears in exactly one cell), all expected cell frequencies are at least 5 (check this before interpreting results), and the total sample size is at least 30. If any expected frequency falls below 5 — common in small samples or sparse tables — switch to Fisher's Exact Test. The test also applies as a goodness-of-fit test (one variable against a theoretical distribution), though the independence form is most frequent.
Strengths & limitations
- Nonparametric — no assumption of normality, suitable for any categorical data.
- Applicable to tables of any dimension (r × c), not just 2 × 2.
- Simple to compute and interpret; Cramér's V provides a standardised effect size.
- One of the most widely reported tests in social, health, and behavioural research.
- Cannot be used when expected cell frequencies fall below 5; Fisher's Exact Test is required instead.
- Does not indicate the direction or nature of the association, only its presence.
- Effect size (Cramér's V) can be difficult to interpret without disciplinary benchmarks.
- Sensitive to sample size — with very large N even trivially small associations become statistically significant.
Frequently asked
What if some expected cell counts are less than 5?
The chi-square approximation becomes unreliable when expected frequencies drop below 5. In that case, use Fisher's Exact Test, which computes an exact p-value without relying on the large-sample approximation. Many software routines print the percentage of cells with expected counts below 5 — treat it as a warning when that percentage exceeds 20%.
What is Cramér's V and how do I interpret it?
Cramér's V is a normalised measure of association derived from the chi-square statistic. It ranges from 0 to 1 regardless of table size: values below 0.10 indicate a weak association, 0.10 to 0.30 moderate, and above 0.30 strong. Always report it alongside the p-value so readers can judge practical significance.
Can I use the chi-square test for ordinal variables?
Technically yes — ordinal variables are categorical — but the chi-square test ignores the natural ordering of categories and therefore discards information. For two ordinal variables, Kendall's tau or Spearman's rho are more powerful because they exploit the order. Reserve the chi-square test for truly nominal categories.
How is this different from a goodness-of-fit chi-square test?
The test of independence compares two categorical variables in a contingency table to assess their association. The goodness-of-fit form compares a single variable's observed frequency distribution against a theoretically expected distribution (e.g., equal proportions or Hardy-Weinberg frequencies). Both use the same statistic and logic, but differ in purpose and in how the expected frequencies are derived.
Sources
- Pearson, K. (1900). On the criterion that a given system of deviations from the probable in the case of a correlated system of variables. Philosophical Magazine, Series 5, 50(302), 157–175. link ↗
How to cite this page
ScholarGate. (2026, June 1). Chi-square goodness-of-fit test. ScholarGate. https://scholargate.app/en/statistics/chi-square
Which method?
Set this method beside its closest kin and read them side by side — the library lays the books on the table; the choice is yours.
- Cramer's VStatistics↔ compare
- Logistic RegressionResearch Statistics↔ compare
- McNemar's testStatistics↔ compare