O'Reilly logo

Logistic Regression Using SAS®: Theory and Application by Paul D. Allison

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

4.3. A Three-Way Table

As we’ve just seen, using GENMOD to estimate a logit model for a 2 × 2 table doesn’t tell you much more than you would get with PROC FREQ. But with a 3-way table, things get more interesting.

Consider Table 4.2, which shows the cross classification of race, gender, and occurrence of sexual intercourse for a national sample of 15- and 16-year-olds, reported by Morgan and Teachman (1988).

Table 4.2. Race by Gender by Sexual Intercourse
  Intercourse
RaceGenderYesNo
WhiteMale43134
 Female26149
BlackMale2923
 Female2236

Let’s analyze Table 4.2 as a logit model, with intercourse as the dependent variable and race and sex as independent variables. Using the events/trials syntax in GENMOD, we have:

DATA interco; INPUT white male yes ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required