Lawrence Hanser
2008-Dec-22 16:31 UTC
[R] post hoc comparisons on interaction means following lme
Dear Colleagues, I have scoured the help files and been unable to find an answer to my question. Please forgive me if I have missed something obvious. I have run the following two models, where "category" has 3 levels and "comp" has 8 levels: mod1 <- lmer(x~category+comp+(1|id),data=impchiefsrm) mod2 <- lmer(x~category+comp+category*comp+(1|id),data=impchiefsrm) followed by: anova(mod1,mod2) The anova shows that the interaction term specified in the second model is significant when added to the main effects model. Now I'd like to run post hoc comparisons using glht to discern where the interaction means differ. For example, for post hoc comparisons on the means of the main effect of "category" I can run: summary(glht(mod2,linfct=mcp(category="Tukey"))) But this only gives me the mean comparisons for the "category" main effect means. Essentially I'd like to run the following: summary(glht(mod2,linfct=mcp(category*comp="Tukey"))) to get the mean comparisons for the interaction means. Perhaps needless to say, this command does not work. Can someone tell me how to run multiple comparisons among the interaction's means? I suspect that specifying the correct contrasts would do it, but I can't figure out how to setup the contrasts... Thanks, Larry [[alternative HTML version deleted]]
Apparently Analagous Threads
- Tukey on interaction means after lmer
- lmer for two models followed by anova to compare the two models
- Is using glht with "Tukey" for lme post-hoc comparisons an appropriate substitute to TukeyHSD?
- glht after lmer with "$S4class-" and "missing model.matrix-" errors
- post hoc test for lme using glht ?