cor2cov: Scales a correlation matrix into the corresponding covariance...

View source: R/stats.R

cor2covR Documentation

Scales a correlation matrix into the corresponding covariance matrix efficiently.

Description

Use sweep. See https://en.wikipedia.org/wiki/Covariance_matrix#Correlation_matrix.

Usage

cor2cov(x, sd)

Arguments

x

correlation matrix

sd

standard deviations

Value

matrix

Author(s)

Timothee Flutre


timflutre/rutilstimflutre documentation built on Feb. 12, 2025, 11:35 p.m.