Say I fit a logistic model and want to calculate an odds ratio between 2
sets of predictors. It is easy to obtain the difference in the predicted
logodds using the predict() function, and thus get a point-estimate OR. But
I can't see how to obtain the confidence interval for such an OR.

 

For example:

model <- glm(chd ~age.cat + male + lowed, family=binomial(logit))

pred1 <- predict(model, newdata=data.frame(age.cat=1,male=1,lowed=1))

pred2 <- predict(model, newdata=data.frame(age.cat=2,male=0,lowed=0))

OR <- exp(pred2-pred1) 

 

Thanks


        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to