#pdf("C:\\Rmisc\\graphs\\kuehl_05_01.pdf") casting <- c(rep(1:3,each=10)) tstrength <- c(88.0,88.0,94.8,90.0,93.0,89.0,86.0,92.9,89.0,93.0, 85.9,88.6,90.0,87.1,85.6,86.0,91.0,89.6,93.0,87.5, 94.2,91.5,92.0,96.5,95.6,93.8,92.5,93.2,96.2,92.5) alloy <- data.frame(casting,tstrength) attach(alloy) casting <- factor(casting) tapply(tstrength,casting,mean) tapply(tstrength,casting,sd) ex_05_01.mod1 <- aov(tstrength ~ casting) summary(ex_05_01.mod1) library(nlme) ex_05_01.mod2 <- lme(fixed=tstrength~1,random=~1|casting) summary(ex_05_01.mod2) library(lme4) ex_05_01.mod3 <- lmer(tstrength~1+(1|casting)) summary(ex_05_01.mod3) #dev.off()