[R] Type II ANOVA for user-defined contrasts with covariates
jfox at mcmaster.ca
Tue Jul 10 03:22:50 CEST 2012
Oddly, essentially the same question was posed by someone else three days ago.
Because groups enters the model additively, the proper test for each contrast is just the t-test for the corresponding coefficient in the summary() for the model.
I hope this helps,
Sen. William McMaster Prof. of Social Statistics
Department of Sociology
Hamilton, Ontario, Canada
On Mon, 9 Jul 2012 20:06:22 +0100
Jordan Ramsey <jmr201 at cam.ac.uk> wrote:
> I'm wondering if anyone would be able to help me out. I'm trying to use a
> type II ANOVA for a model with user-specified contrasts and covariates.
> I have two treatment groups and a control group. I'm comparing average
> treatment to controls and also between the two treatment groups, but I'm
> also looking to adjust for age and gender as covariates:
> since I'm interested in SS(R | A,G,AG)
> I was hoping then to use the Anova() function in the car() package to find
> the type II ANOVA for my specified contrasts, but when I do so it only
> looks at Response as a whole instead of the two contrasts. Any ideas where
> I'm going wrong?
> [[alternative HTML version deleted]]
> R-help at r-project.org mailing list
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
More information about the R-help