SIM.FUN: Generate simulation data to test adaptive lasso

Description Usage Arguments Value Author(s) Examples

View source: R/simulation.R

Description

SIM.FUN generates binary, count, and continuous-time survival response data that are associated with design matrix. The design matrix comes from a correlated multivariate normal. The default signals (beta0) are sparse.

Usage

1
2
SIM.FUN(nn, p.x = 50, cor = 0.2, family = c("binary", "count", "Cox"),
  beta0 = NULL)

Arguments

nn

sample size

p.x

number of covariates

cor

correlation of covariates

family

the family of response data taking c('binary','count','Cox')

beta0

the coefficients for the design, including intercept

Value

For binary and count data, it returns a matrix with the first column=response, rest = design matrix, without intercept. For survival data, it returns a matrix with the first column U, second column delta (0,1), and rest = design matrix.

Author(s)

Yan Wang, Tianxi Cai

Examples

1
SIM.FUN(nn = 1e6, p.x = 50, family = 'binary')

michaelyanwang/divideconquer documentation built on Aug. 16, 2019, 10:11 a.m.