gendata_Mean {TOSI} | R Documentation |
Generate simulated data
Description
Generate simulated data from for high-dimensional mean model.
Usage
gendata_Mean(n, p, s0= floor(p/2), seed=1, rho= 1, tau=1)
Arguments
n |
a positive integer, the sample size. |
p |
an positive integer, the variable dimension. |
s0 |
a positive integer, the number of nonzero components of mean . |
seed |
a nonnegative integer, the random seed, default as 1. |
rho |
a positive number between 0 and 1, controlling the correlation of data. |
tau |
a positive number, controlling the magnitude of covriance matrix. |
Value
return a list including two components:
X |
a |
mu |
a p-dimensional vector, the mean vector. |
p0 |
a integer vector, the number of nonzero components of mean. |
Note
nothing
Author(s)
Liu Wei
Examples
dat <- gendata_Mean(n=100, p = 100, s0=3)
str(dat)
[Package TOSI version 0.3.0 Index]