GenerateCliquesCovariance: Generate a block diagonal covariance matrix

View source: R/generate_sigma.R

GenerateCliquesCovarianceR Documentation

Generate a block diagonal covariance matrix

Description

This function is included in the package so that it can be used in the example code provided in spcov.

Usage

GenerateCliquesCovariance(ncliques, cliquesize, theta)

Arguments

ncliques

number of blocks

cliquesize

size of each block

theta

magnitude of non-zeros

Details

This function generates a block diagonal positive definite matrix with randomly-signed, non-zero elements. A shift is added to the diagonal of the matrix so that its condition number equals p, the number of variables.

Value

Sigma

the covariance matrix

A

symmetric square root of Sigma

shift

how much the eigenvalues were shifted. See details.

Author(s)

Jacob Bien and Rob Tibshirani

References

Bien, J., and Tibshirani, R. (2011), "Sparse Estimation of a Covariance Matrix," accepted for publication in Biometrika.


spcov documentation built on Sept. 24, 2022, 1:08 a.m.