## Chi Square: Goodness-Of-Fit v. Test of Independence

**What is Chi Square?**

Statistics like t-tests and ANOVA are applicable for interval and ratio variables, when the dependent variables being measured are continuous. **On the other hand, chi-square applies when the variables are nominal or ordinal.** Chi-square tests if one group of amounts is higher or lower than you would expect by coincidence.

According to Marczyk, DeMatteo, & Festinger (2005):

Chi-square summarizes the discrepancy between observed and expected frequencies. The smaller the overall discrepancy is between the observed and expected scores, the smaller the value of the chi-square will be. Conversely, the larger the discrepancy is between the observed and expected scores, the larger the value of the chi-square will be (p. 223).

**Goodness-Of-Fi****t ****VS.****Test of Independence**

**Goodness-Of-Fit**

A goodness-of-fit test is a one variable Chi-square test. According to Steinberg (2011), “the goal of a Chi-square goodness-of-fit test is to determine whether a set of frequencies or proportions is similar to and therefore “fits” with a hypothesized set of frequencies or proportions” (p. 371). A Chi-square goodness-of-fit test is like to a one-sample t-test. It determines if a sample is similar to, and representative of, a population.

**Example of ****Goodness-Of-Fit****:**

We might compare the proportion of M&M’s of each color in a given bag of M&M’s to the proportion of M&M’s of each color that Mars (the manufacturer) claims to produce. In this example there is only one variable, M&M’s. M&M’s can be divided into many many categories like Red, Yellow, Green, Blue, and Brown, however there is still only one variable… M&M’s.

Hungry?

Steinberg (2011), notes: “the Chi-square goodness-of-fit test will determine whether or not the relative frequencies in the observed categories are similar to, or statistically different from, the hypothesized relative frequencies within those same categories (p. 371).

**Test of Independence**

A test of independence is a two variable Chi-square test. Like any Chi-square test the data are frequencies, so there are no scores and no means or standard deviations. Steinberg (2011) points out, “the goal of a two-variable Chi-square is to determine whether or not the first variable is related to—or independent of—the second variable” (p. 382). A two variable Chi-square test or test of independence is similar to the test for an interaction effect in ANOVA, that asks: Is the outcome in one variable related to the outcome in some other variable” (Steinberg, 2011) (p. 382).

**Example of ****Test of Independence**

To continue with the M&M’s example, we might investigate whether purchasers of a bag of M&M’s eat certain colors of M&M’s first. Here there are two variables: (1) M&M’s (2) The order based on color that an M&M bag holder/purchaser eats the candies.

Steinberg, W. J. (2011). *Statistics alive!* (2nd ed.). Thousand Oaks, CA: Sage Publications.

Marczyk, G., DeMatteo, D., & Festinger, D. (2005). *Essentials of research design and methodology*. Hoboken, NJ: John Wiley & Sons.