lv {VGAM} | R Documentation

## Latent Variables

### Description

Generic function for the latent variables of a model.

### Usage

    lv(object, ...)

### Arguments

`object` | An object for which the extraction of latent variables is meaningful.
`...` | Other arguments fed into the specific methods function of the model. Sometimes they are fed into the methods function for `Coef`.

### Details

Latent variables occur in reduced-rank regression models, as well as in quadratic and additive ordination models. For the latter two, latent variable values are often called site scores by ecologists. Latent variables are linear combinations of the explanatory variables.

### Value

The value returned depends specifically on the methods function invoked.

### Note

Latent variables are not really applicable to `vglm`/`vgam` models.

### Author(s)

Thomas W. Yee

### References

Yee, T. W. and Hastie, T. J. (2003) Reduced-rank vector generalized linear models. Statistical Modelling, 3, 15–41.

Yee, T. W. (2004) A new technique for maximum-likelihood canonical Gaussian ordination. Ecological Monographs, 74, 685–701.

Yee, T. W. (2006) Constrained additive ordination. Ecology, 87, 203–213.

### See Also

`lv.qrrvglm`, `lv.rrvglm`, `lv.cao`, `lvplot`.

### Examples

    ## Not run:
    hspider[,1:6] = scale(hspider[,1:6]) # Standardized environmental vars
    set.seed(123)
    p1 = cao(cbind(Pardlugu, Pardmont, Pardnigr, Pardpull, Zoraspin) ~
             WaterCon + BareSand + FallTwig +
             CoveMoss + CoveHerb + ReflLux,
             family = poissonff, data = hspider,
             Rank = 1, df1.nl = c(Zoraspin=2.5, 3),
             Bestof = 3, Crow1positive = TRUE)

    var(lv(p1))  # Scaled to unit variance  # Scaled to unit variance
    c(lv(p1))    # Estimated site scores
    ## End(Not run)

[Package VGAM version 0.7-9 Index]