I have the following formula for a linear model: z <- lm(y~x + factor(a) + factor(b), data=NT2010)
where a (groups) and b (Sub-groups) are categorical variables (factors), x is a continuous covariate, and y the response variable. Since b is nested within a, the formula can also be written as: z <- lm(y~x + factor(a) + factor(a)/factor(b), data=NT2010) and the same output is achieved when summary(z) is called. How can I get the output to show all 3 groups that I have inputted? There are only group 2 and group 3 on the output, group 1 is missing. Also there is a subgroup (subgroup 1) of the total 9 subgroups missing. I would like to see the p-value of the missing group and missing sub-group even though I'm sure they are not significantly different (>0.05). How do I change the original formula to get all groups and sub-groups outputted? [[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.