# 15. Chi Squared: Goodness of Fit and Contingency Tables

Recall that the is essentially the distribution of sample variances from a normal population. It has three important applications (there are others) :

1. Hypothesis test of population variance (covered in Section 9.5).
2. Model fitting through (not covered in this course).
3. Hypothesis test of frequencies :
a) Goodness of fit
b) contingency tables.

Here we focus on the last application. We will use the statistic to compare the measured (or observed) statistic with expected () frequencies. The difference of observed and expected frequencies squared represents a variance. If the difference between observed and expected frequencies is due to noise, which will have some sort of binomial distribution, then we expect the statistic to be low. If the difference between observed and expected frequencies is large then there must be an effect other than noise that is causing that difference.