if (FALSE) {
library(agridat)
data(stickler.sorghum.uniformity)
dat <- stickler.sorghum.uniformity
dat1 <- subset(dat, expt=="E1")
dat2 <- subset(dat, expt!="E1")
libs(desplot)
desplot(dat, yield ~ col*row|expt,
subset=expt=="E1",
#cex=1,text=yield, shorten="none",
xlab="row",ylab="range",
flip=TRUE, tick=TRUE, aspect=(20*10)/(20*14/12), # true aspect
main="stickler.sorghum.uniformity: expt E1")
desplot(dat, yield ~ col*row|expt,
subset=expt!="E1",
xlab="row",ylab="range",
flip=TRUE, tick=TRUE, aspect=(20*5)/(20*44/12), # true aspect
main="stickler.sorghum.uniformity: expt E2,E3,E4")
# Stickler, p. 10-11 has
# E1 E2 E3 E4
# 34.81 11.53 11.97 14.10
cv <- function(x) 100*sd(x)/mean(x)
tapply(dat$yield, dat$expt, cv)
# 35.74653 11.55062 11.97011 14.11389
}
Run the code above in your browser using DataLab