I have data of an experiment where subjects performed a task under 4 conditions (A1B1, A1B2, A2B1, A2B2, where A1/A2 are the levels of factor IV1
and B1/B2 those of IV2
) with repeated measures on both factors, and I gather that one needs to account for a subject effect (id
) — are these the residuals that should be normally distributed if I want the p-values of the IV1
, IV2
, IV1xIV2
effects from an ANOVA to be meaningful? In R:
fit <- lm(DV ~ IV1*IV2 + id, myData)
residuals(fit)
Thanks!