Skip to contents

This function rescales a covariance matrix using either the Cholesky decomposition method or a simple diagonal adjustment.

Usage

rescale_cov(Sigma, Scale_factor, DoChol = FALSE)

Arguments

Sigma

A covariance matrix that needs to be rescaled.

Scale_factor

A numeric value or vector used for scaling.

DoChol

Logical indicating if the Cholesky decomposition method should be used. If FALSE, the simple diagonal adjustment method is used. Default is FALSE.

Value

A rescaled covariance matrix.