R: Variance structure spanning several model terms

complex_vs {asreml} | R Documentation

## Variance structure spanning several model terms

### Description

General variance structure specifying a set of terms to be included in the random argument that collectively will have an associated variance model.

### Usage

    str(form, vmodel)

### Arguments

`form` | A model formula included verbatim in the `asreml()` `random` argument.
`vmodel` | A direct product variance model for the set of terms given in `form`.

### Details

Typically, a variance structure applies to an individual term (main effect or interaction) in the linear model, and there is no covariance between random model terms. Sometimes it is appropriate to include a covariance, such as random coefficients regression. In such cases it is essential that the model terms be contiguous and that the variance structure defined is the structure required across all terms in the set.

The model terms in `form` are consequently not reordered. While `asreml` will check the overall size of the included terms, it cannot check that the order of effects matches the structure definition in `vmodel`; care must be taken to ensure this is correct. Check that the terms are conformable by considering the order of the fitted effects and ensuring the first term of the direct product in `vmodel` corresponds to the outer factor in the nesting of the effects in `form`.

[Package asreml version 4.2.0.480 Index]