ContingencyAnalysis Example from Zar (1999)
Biostatistics BI 45, Saint Anselm College
Step 1) State the biological question.
Is there a relationship between human hair color and sex in a population or is hair color independent of sex?
Step 2) Translate the biological question into statistical hypotheses.
Step 3) State the alpha level.
Step 4) State the statistical test.
Because we are comparing distributions of groups with two or more variables and assessing independence among all variables we would use a Chi Square contingency analysis.
Step 5) State the assumptions of the test.
We assume that the data were obtained from a randomly sampled population and that the categories are mutually exclusive.
Step 6) Calculate the observed Chi Square statistic from your data.
| Sex | Black | Brown | Blond | Red | Total |
| Male-obs | 32 | 43 | 16 | 9 | 100 |
| Male-exp | 29 | 36 | 26.67 | 8.33 | |
| calculations | 100(25)/300 | ||||
| Female-obs | 55 | 65 | 64 | 16 | 200 |
| Female-exp | 58 | 72 | 53.33 | 16.67 | |
| calculations | 200(25)/300 | ||||
| Total | 87 | 108 | 80 | 25 | 300 |

Step 7) Find the df and critical value of Chi Square from the table of critical values.
Step 8) Compare the critical and observed Chi Square values and reject or do not reject the null hypothesis.

Find the actual P value
X2.05,3=7.815<X2obs=8.987<X2.025,3=9.348
0.025<P<0.05
Step 9) Interpret the results of the analysis as it relates to the biological question raised in 1).
We rejected the null hypothesis in Step 8. There is a relationship between hair color and sex (Chi Square=8.987, df=3, p<0.05).
Blackboard at Saint Anselm College
Trademark and Disclaimers
Copyright © 2001 Jay Pitocchelli. All rights reserved. The contents of this page are the intellectual property of Dr. Jay Pitocchelli for distribution to students enrolled in Biostatistics BI 45 at Saint Anselm College. These pages may not be copied, photocopied, reproduced, translated, or published in any electronic or machine-readable form in whole or in part without prior written approval of Jay Pitocchelli. Students enrolled in Biostatistics BI 45 at Saint Anselm College have permission to print this material for their lecture notes. All formulae and critical values from: Zar, J. H. 1999. Biostatistical Analysis. (4th ed.). New Jersey, Prentice Hall.