











































Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
An introduction to categorical data analysis, focusing on contingency tables and the test of independence. It covers the concept of a two-way contingency table, notation, scenarios where it arises, and the test of independence. The document also discusses the pearson chi-square statistic and the test for trend.
Typology: Study notes
1 / 51
This page cannot be seen from the preview
Don't miss anything!












































Categorical Data: Contingency Tables Bios 662
Michael G. Hudgens, Ph.D. [email protected] http://www.bios.unc.edu/∼mhudgens 2006-10-17 17:
Contingency Tables
j i 1 2 · · · c 1 n 11 n 12 · · · n 1 c 2 n 21 n 22 · · · n 2 c ... ... ... ... ... r nr 1 nr 2 · · · nrc
ni· =
∑^ c
j=
nij n·j =
∑^ r
i=
nij
Contingency Table: Example
Contingency Table: Example
Contingency Tables
Test of Independence or Association
Eij =
ni·n·j N
Test of Independence
(r − 1)(c − 1) = 3 × 3 = 9
C. 05 = {X^2 : X^2 > χ^2. 95 , 9 = 16. 92 }
Physician’s Example
Practice Reared <5k 5-49k 50-99k 100k+ Total <5k 30.4 36.8 39.0 40.8 147 5-49k 28.1 34.0 36.1 37.8 136 50-99k 23.8 28.8 30.5 31.9 115 100k+ 37.7 45.5 48.3 50.5 182 120 145 154 161 580
Breast Cancer Example
Age at 1st birth <20 20-24 25-29 30-34 ≥ 35 Total Case π 11 π 12 π 13 π 14 π 15 1 Control π 21 π 22 π 23 π 24 π 25 1
Breast Cancer Example
H 0 : π 1 j = π 2 j for j = 1, 2 , 3 , 4 , 5
X^2 =
i=
∑^ c
j=
(Oij − Eij)^2 Eij^ ∼^ χ
2 (c−1)
Breast Cancer Example
X^2 = (320^ −^416 .6)
2
C. 05 = {X^2 : X^2 > χ^2. 95 , 4 = 9. 49 }
Asymptotic Approximation
Test for Trend
Test for Trend