Compound-symmetry covariance structure. The returned dimensionless covariance shape is intended for use inside vsm, which supplies the single overall variance scale.
csm(x, rho = 0.10, fixed = FALSE,
variance = c("homogeneous", "heterogeneous"), values = NULL)A list containing the incidence/design matrix in Z and a compiled CovarianceFactor v2 descriptor in covFactor, for use inside vsm.
Variable defining q covariance levels.
Starting common off-diagonal correlation.
For homogeneous variance, a logical indicating whether rho is fixed. For heterogeneous variance, a logical vector of length q: rho followed by q-1 variance-ratio parameters.
Whether the correlation has homogeneous or heterogeneous marginal variances.
Optional q positive starting variances when variance = "heterogeneous".
With variance = "homogeneous", csm uses unit diagonal and a common off-diagonal correlation, $$K_{ii}=1, \quad K_{ij}=\rho\ (i\ne j).$$ With variance = "heterogeneous", it uses $$K=D C(\rho)D,$$ where the first variance is the reference and the remaining q-1 variances are estimated as positive ratios. Positive definiteness requires \(-1/(q-1)<\rho<1\). The product-level variance remains owned by vsm.
corgm, dsm, vsm.
if (FALSE) {
vsm(csm(environment), ism(genotype))
}
Run the code above in your browser using DataLab