Chi-Squared Tests: Inference for Two-Way Tables
Chi-squared ("Chi" rhymes with "pie") tests have many uses. This page discusses the basis for all chi-squared tests. There are links at the bottom of this page for specific chi-squared tests.
Purpose: To test whether there is an association between two or more categorical variables.
Requirements: Set up a two-way table of observed counts. Use it to compute the expected counts for each cell in the table, thus:. The required conditions for the tests are
(1) The data are from one or more (independent) simple random samples. (The exact randomness requirements depend on the actual design of the experiment.)
(2) All expected counts are greater than 1.
(3) No more than 20% of the expected counts are less than 5.
There is no association between the two variables, versus There is an association between the two variables. These hypotheses can be specialized to a stunning variety of more specific hypotheses. See the links at the bottom of this page for more information.
Test Statistic: We recommend using software such as SPSS to calculate the test statistic, the degrees of freedom, and the p-value. However, you can use the formula , with degrees of freedom, and get the p-value from a table such as Table F in Moore & McCabe’s The Practice of Business Statistics.
WARNING: The test statistic is very sensitive to round-off errors made during calculation. We recommend using the above formula instead of the one usually found in textbooks, as it suffers less from this problem. Also, we recommend entering the entire calculation in your calculator all at once, rather than computing each term separately, to help minimize round-off error.
Instructions on using SPSS for chi-squared tests: Click here.
Tests of independence
Tests of homogeneity (several proportions)
Comparing unknown populations
Goodness-of-fit (comparing populations when one population is “known”)
Statistics Reference Pages page: Click here.
David E. Brown
232 Ricks Building 208-496-1839 voice
Rexburg, ID 83460 208-496-2005 fax
Please do not call me at home.