generate_inv_cov: generate_inv_cov

Description Usage Arguments Details Value Examples

View source: R/netsim.R

Description

Generate an inverse covariance matrix with a given sparsity and dimensionality

Usage

1
generate_inv_cov(p = 162, sparsity = 0.7)

Arguments

p

Dimensionality of the matrix.

sparsity

Determined the proportion of non-zero off-diagonal entries.

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.

Value

A p by p positive definite inverse covariance matrix.

Examples

1

FrankD/nethet documentation built on Oct. 5, 2020, 8:22 a.m.