rcor | R Documentation |
Extract the R-side variance components from a fitted model (asreml or lme) and format them as matrices.
rcor(obj)
## S3 method for class 'gls'
rcor(obj)
## S3 method for class 'asreml'
rcor(obj)
## S3 method for class 'asremlrmat'
print(x, n = 6, dig = 3, ...)
obj |
A fitted model object. |
x |
Object to print |
n |
Size of matrix corner to print |
dig |
Number of digits for printing |
... |
Other arguments (not used) |
A list of matrices.
## Not run:
require('agridat')
dat <- hanks.sprinkler
dat <- transform(dat, subf=factor(subplot),
irrf=factor(irr))
dat <- dat[order(dat$block, dat$gen, dat$subplot),]
m1 <- asreml(yield ~ gen + dir + irrf + gen:dir + gen:irrf + dir:irrf,
data=dat,
random= ~ block + block:dir + block:irrf,
rcov= ~ block:gen:corb(subf, k=3))
require("lucid")
lucid(rcor(m1)$subf[1:8,1:8],dig=2)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.