dat <- minnesota.barley.yield
dat$yr <- factor(dat$year)
# Drop Dryland, Jeans, CompCross, MechMixture because they have less than 5
# year-loc values
dat <- droplevels(subset(dat, !is.element(gen, c("CompCross","Dryland","Jeans","MechMixture"))))
# 1934 has huge swings from one loc to the next
dotplot(gen~yield|site, dat, groups=yr,
auto.key=list(columns=5), scales=list(y=list(cex=.5)))Run the code above in your browser using DataLab