On Wed, 18 Oct 2006, SCHMERA D?nes wrote:

Dear All,

I would like to run a generalized linear mixed model with the software R (one 
categorical predictor, one random factor, the distribution of the dependent 
variable is binomial, and the link is logit). Thereafter, I would like to 
perform multiple comparisons (post hoc test) among the groups of the 
categorical predictor.

Is it possible with the software R?


yes and no. There is the `multcomp' package available but the CRAN version is limited to linear models (more or less). However, I'm currently working on a re-implementation which has solutions for your problem and much more :-)

For the time being, the development version is available from

        http://www.imbe.med.uni-erlangen.de/~hothorn/multcomp2

The basic steps would be as follows:

### fit logistic regression model
my.glm <- glm(response ~ myfactor, data = <mydata>, family = binomial())
### set up linear hypothesis for coef(my.glm) corresponding to all-pair ### comparisons
library("multcomp2")
gh <- glht(my.glm, linfct = mcp(myfactor = "Tukey"))
### simultaneous confidence intervals with plots
confint(gh)
plot(confint(gh))

Hope that helps.

Torsten

Are traditional methods of multple comparisons (for instance Tukey test) 
adequate for this purpose or not? Does Tukey test consider the binomial 
dsitribution of the dependent variable and the logit link?

I am waiting for your answer,
Denes Schmera

______________________________________________
R-help@stat.math.ethz.ch 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.
______________________________________________
R-help@stat.math.ethz.ch 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