Learn R Programming

agridat (version 1.12)

burgueno.alpha: Incomplete block alpha design

Description

Incomplete block alpha design

Usage

data("burgueno.alpha")

Arguments

Format

A data frame with 48 observations on the following 6 variables.

rep

rep factor, 3 levels

block

block factor, 12 levels

row

row ordinate

col

column ordinate

gen

genotype factor, 16 levels

yield

yield, numeric

Details

A field experiment with 3 reps, 4 blocks per rep, laid out as an alpha design.

Examples

Run this code
# NOT RUN {
data(burgueno.alpha)
dat <- burgueno.alpha

desplot(yield~col*row, dat, main='burgueno.alpha', out1=rep, out2=block,
        text=gen, cex=1,shorten="none")

if(require(lme4) && require(lucid)){
  # Inc block model
  m1 <- lmer(yield ~ gen + (1|rep/block), data=dat)
  vc(m1) # Matches Burgueno p. 26
  ##        grp        var1 var2   vcov sdcor
  ##  block:rep (Intercept) <NA>  86900 294.8
  ##        rep (Intercept) <NA> 200900 448.2
  ##   Residual        <NA> <NA> 133200 365
}

# }
# NOT RUN {
  require(asreml)
  # Inc block model
  m2 <- asreml(yield ~ gen, data=dat, random = ~ rep/block)
  m2$loglik # Matches Burgueno p. 26
  m2$coef$fixed # Matches solution on p. 27

  # AR1 x AR1 model plus linear row effect, random spline row
  dat <- transform(dat, xf=factor(col), yf=factor(row))
  dat <- dat[order(dat$xf,dat$yf),]
  m3 <- asreml(yield ~ gen + lin(yf), data=dat, random = ~ spl(yf),
               rcov= ~ar1(xf):ar1(yf))
  m3$loglik # Matches row 8 of Table 1
  plot(variogram(m3), main="burgueno.alpha") # Figure 1
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab