Displaying 1 result from an estimated 1 matches for "simdata3".
Did you mean:
simdata
2008 Mar 05
2
simulating the anova
I have been trying to figure out how to run a simple simulation of the ANOVA
and I'm coming up just a bit short. The code I've got is:
cohen.f = .25
groups = 4
between.var = 19
within.var = between.var / cohen.f ^ 2
n = 500
sim.means = rnorm(n = groups, mean = 0, sd = sqrt(between.var))
sim.data = lapply(sim.means, function(mean) rnorm(n = n, mean = mean, sd =
sqrt(within.var)))