Hi, I fitted a linear model: fit <- lm(y ~ a * b + c - 1 , na.action='na.omit') Now I want to extract only the a * b effects with confidence intervals. Of course, I can just add the coefficients by hand, but I think there should an easier way. I tried with predict.lm using the 'terms' argument, but I didn't manage to do it. Any hints are appreciated, best, joerg
> I fitted a linear model: > fit <- lm(y ~ a * b + c - 1 , na.action='na.omit')wouldn't a simple coef(fit)[2] work? Jukka Ruohonen.> ______________________________________________ > R-help at 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
Hi, I fitted a mixed linear model y = a + b + a*b + c + error, with c being the random factor: lmefit <- lme(y ~ a * b - 1 , random = ~ 1 | c, na.action='na.omit') Is there a way to omit some level combinations of the cross-term a:b? E.g. those that are not significant? When I add the coefficients of a, b and a:b to get the combined effect without the effect of c, do then the standard errors of the coefficients also add? best, joerg