Greg Snow | 1 Dec 19:31

Re: Randomization of a two-way ANOVA?

This really depends on the question(s) that you are asking.

If you want a simultaneous test of all your factors, then you can randomly permute the response many times
and see where the original f-stat (or others) falls in the distribution of the randomized stats.

If you want to test the interaction, then fit the full model and save the f-stat for the interaction term.  Fit
the model without the interaction and save the residuals and fitted values, permute the residuals and add
them back to the fitted values, then analyze this with the full model and save the f-stat.  Repeate and see
how the f-stat (or other stat) of the original fit compares to the permuted stats.

For combinations of other questions, just do the same as above but with the full and reduced model that
matches the question(s) of interest.

You could also do bootstrapping as a randomization test, there are a couple of packages that help with that
(but it is also easy without the packages), but for testing, I prefer the permutation test.

Hope this helps,

--
Gregory (Greg) L. Snow Ph.D.
Statistical Data Center
Intermountain Healthcare
greg.snow <at> imail.org
801.408.8111

> -----Original Message-----
> From: r-help-bounces <at> r-project.org [mailto:r-help-bounces <at> r-
> project.org] On Behalf Of Joe Ratster
> Sent: Sunday, November 30, 2008 1:22 PM
> To: r-help <at> r-project.org
(Continue reading)


Gmane