covgen: covgen

Description

generates random definite positive matrices (i.e. valid covariance matrices).

Usage

1
covgen(d = 2, bounds = c(1, 5))

Arguments

d

rank of the square matrix to be returned.

bounds

minima and maximal values for diagonal values.

Value

random definite positive matrix

Note

Matrix cells are sampled with an heuristic not guaranteed to lead to definite positiveness: this characteristic is only controlled before function return. If positive definite after control, the matrix is returned. If not, an error message is issued.

Author(s)

Pierrick Bruneau

See Also

randomGmm

Examples

1
temp <- covgen()

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

All documentation is copyright its authors; we didn't write any of that.