SIM.FUN
generates 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.
SIM.FUN(nn, p.x = 50, cor = 0.2, family = c("binary", "count", "Cox"), beta0 = NULL)
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 |
For survival data, it returns a matrix with the first column U, second column delta (0,1), and rest = design matrix.
Yan Wang, Tianxi, Chuan Hong