scramble_covmat: Scramble a covariance matrix

Description Usage Arguments Value Examples

View source: R/stats.R

Description

Scramble a covariance matrix

Usage

1

Arguments

x

a square covariance matrix

seed

set seed number

order

custom ordering of index values with range 1:ncol(x)

Value

matrix

Examples

1
2
3
4
5
6
x <- rcov(1, 4)
y <- scramble_covmat(x, 20131001)
print(matrix(sprintf('%+.3f', x), ncol=4))
print(matrix(sprintf('%+.3f', y), ncol=4))
det(x)
det(y)

iamamutt/mejr documentation built on May 18, 2019, 1:27 a.m.