Pages

4/19/2011

Power of test

It has been a while since I took the design of experiment course. I was asked about the power of test today and it took me a while to figure out the correct way to generate the power of test table in R. I'll just paste it here for future reference

phi <- 0.7217 
nv1 <- 2 #Numerator d.f.
nv2 <- 9 #Denominator d.f.
nu <- nv1 + 1
Falpha <- qf(0.95,2,9)
#Non Central Parameter (ncp) = nu*pi^2
1- pf(Falpha,2,9,ncp = nu * phi^2)

No comments:

Post a Comment