strsimdata: Structured Simulate Data sets

Description Usage Arguments Details Value

View source: R/src.r

Description

This is a function for generating multiblock data based on the multivariable normal distribusion

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
strsimdata(
  n = 100,
  WX = NULL,
  ncomp = 5,
  Xps = 10,
  Yps = FALSE,
  rho = 0.8,
  Ztype = c("none", "binary", "prob")[1],
  cz = c(1, 1),
  cwx = c(0.1, 0.1),
  cwy = c(0.1, 0.1),
  seed = 1,
  minpct = 0.25,
  maxpct = 0.75
)

Arguments

n

a numeric scalar, sample size.

WX

a matrix or a list, weights.

ncomp

number of components

Xps

a numeric vector, numbers of columns for X. The length of vector corresponds to the number of blocks.

Yps

a numeric vector, numbers of columns for Y. The length of vector corresponds to the number of blocks.

rho

a numeric, correlation

Ztype

a character, outcome type ("none", "binary", "prob").

cz

a numeric vector, scale for outcome

cwx

a numeric vector, scale for weights of X

cwy

a numeric vector, scale for weights of Y

seed

a seed number for generating random numbers.

minpct

minimum percent of nonzero

maxpct

maximum percent of nonzero

Details

The output is a list of matrics.

Value

X

Simulated X which has a list form

Y

Simulated Y which has a list form

Z

Simulated Z which has a vector form

ncomp
Xps
nZeroX
idxZeroX
Yps
nZeroY
idxZeroY
WX
WY
ZcoefX
ZcoefY

msma documentation built on June 25, 2021, 5:09 p.m.