cor2cov: Correlation Matrix to Covariance Matrix convert a correlation...

View source: R/cor2cov.R

cor2covR Documentation

Correlation Matrix to Covariance Matrix convert a correlation matrix and variance vector into the corresponding covariance matrix. A warning is given if the covariance matrix is not positive definite.

Description

Correlation Matrix to Covariance Matrix convert a correlation matrix and variance vector into the corresponding covariance matrix. A warning is given if the covariance matrix is not positive definite.

Usage

cor2cov(corMat, varVec)

Arguments

corMat

is a square matrix with 1's on the diagonal

varVec

is a valid variance vector, with length

Value

Covariance matrix


jlivsey/livsey documentation built on Oct. 17, 2024, 3:18 a.m.