Generate an inverse covariance matrix with a given sparsity and
dimensionality
Usage
generate_inv_cov(p = 162, sparsity = 0.7)
Arguments
p
Dimensionality of the matrix.
sparsity
Determined the proportion of non-zero off-diagonal entries.
Value
A p by p positive definite inverse covariance matrix.
Details
This function generates an inverse covariance matrix, with at most
(1-sparsity)*p(p-1)
non-zero off-diagonal entries, where the non-zero entries are sampled from a
beta distribution.