[R] Odds ratios in logistic regression models with interaction

Michael Dewey lists at dewey.myzen.co.uk
Thu Aug 4 14:32:20 CEST 2016


Laviolette, Michael <Michael.Laviolette at dhhs.nh.gov> wrote :

> I'm trying to reproduce some results from Hosmer & Lemeshow's "Applied Logistic
> Regression" second edition, pp. 74-79. The objective is to estimate odds ratios
> for low weight births with interaction between mother's age and weight
> (dichotomized at 110 lb.). I can get the point estimates, but I can't find an
> interval option. Can anyone provide guidance on computing the confidence
> intervals?

There is always confint. Not sure if you need MASS first from memory, not got a copy of R running to hand.


 Thanks. -Mike L.
> 
> library(dplyr)
> data(birthwt, package = "MASS")
> birthwt %
>   mutate(low = factor(low, 0:1, c("Not low", "Low")),
>          lwd = cut(lwt, c(0, 110, Inf), right = FALSE,
>                    labels = c("Less than 110", "At least 110")),
>          lwd = relevel(lwd, "At least 110"))
> 
> # p. 77, Table 3.16, Model 3
> fit3.16



More information about the R-help mailing list