View source: R/emxBehaviorGenetics.R
emxGeneticFactorVariance | R Documentation |
This function creates a variance matrix according to the genetic factor model
emxGeneticFactorVariance(x, name, values=.8, free=TRUE, lbound=NA, ubound=NA)
x |
character vector. The names of the variables used for the matrix. |
name |
character. The name of the variance matrix created. |
values |
numeric vector. The starting values for the lower triangular matrix. |
free |
logical vector. Whether the lower triangular elements are free. |
lbound |
numeric vector. Lower bounds on free parameters. |
ubound |
numeric vector. Upper bounds on free parameters. |
A list with two components. The first component is the factor loadings matrix. The second component is an MxAlgebra, the result of which is the variance matrix implied by the factor loadings.
emxCholeskyVariance
# Create a genetic factor variance matrix require(EasyMx) xvars <- paste0('x', 1:2) emxGeneticFactorVariance(xvars, 'D')
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.