Learn R Programming

mhtboot (version 1.3.3)

datgen: datgen

Description

Function to generate data from multivariate normal with different mean.

Usage

datgen(n, m, m0, sigeff, Sigma)

Arguments

n
number of samples
m
number of cords
m0
number of non sparse elements
sigeff
magnitude of signal
Sigma
Covariance matrix

Value

X data matrix of size nxm

Details

This function generates data from multivariate normal distribution with given covariance matrix. The mean values are either zero or constant sigeff, randomly permuted among the coordinates.

Examples

Run this code
## Not run: 
# n = 50;m = 250;m0 = 20;
# sigeff = 1;
# Sigma <- 0.25*diag(m)
# X <- datgen(n,m,m0,sigeff,Sigma = Sigma)
# ## End(Not run)

Run the code above in your browser using DataLab