if (FALSE) {
library(agridat)
data(cochran.factorial)
dat <- cochran.factorial
# Ensure factors
dat <- transform(dat, d=factor(d), n=factor(n), p=factor(p), k=factor(k))
# Cochran table 6.5.
m1 <- lm(yield ~ rep * block + (d+n+p+k)^3, data=dat)
anova(m1)
libs(FrF2)
aliases(m1)
MEPlot(m1, select=3:6,
main="cochran.factorial - main effects plot")
}
Run the code above in your browser using DataLab