cov_2_chol {oeli} | R Documentation |
These functions compute the Cholesky root elements of a covariance matrix and, conversely, build a covariance matrix from its Cholesky root elements.
cov_2_chol(cov, unique = TRUE)
chol_2_cov(chol)
unique_chol(chol)
cov |
A covariance |
unique |
Set to |
chol |
A |
For cov_2_chol
a numeric
vector
of Cholesky root
elements.
For chol_2_cov
a covariance matrix
.
cov <- sample_covariance_matrix(4)
chol <- cov_2_chol(cov)
all.equal(cov, chol_2_cov(chol))