powered by
Data from the General Social Survey, 1991, on the relation between sex and party affiliation.
data(GSS)
A data frame in frequency form with 6 observations on the following 3 variables.
sex
a factor with levels female male
female
male
party
a factor with levels dem indep rep
dem
indep
rep
count
a numeric vector
# NOT RUN { data(GSS) ## maybe str(GSS) ; plot(GSS) ... (GSStab <- xtabs(count ~ sex + party, data=GSS)) mod.glm <- glm(count ~ sex + party, family = poisson, data = GSS) # }
Run the code above in your browser using DataLab