Simulate regression, classification or survival outcome based on feature matrix and effect vector
Arguments
- X
Prepared feature matrix (as tibble or matrix) with standardized and potentially log-transformed numeric variables and dummy-coded categorical variables. If interaction effects are desired, a corresponding column has to be present in
X
(e.g.X$interaction_A_B = X$A*X$B
). Needs to contain an id column named ".id".- beta
Named effect vector with the corresponding effects for the columns in
X
. Only non-zero effects have to be specified- type
type of the simulated outcome: "regression", "classification" or "survival"
- ctrl_regr
list with the settings for regression outcome, simulated by a linear regression model
b0
model intercept
sd
standard deviation of the model error term
- ctrl_class
list with settings for classification outcome (event vs. no event), simulated by a logistic regression model
prob_ev
event probability
mult_beta
enhancement factor for the beta coefficient to control signal-to-noise ratio
- ctrl_surv
list with settings for right-censored survival outcome, simulated by a proportional hazard model with time-constant baseline hazard
surv_mean
mean survival time
cens_mean
mean censoring time, NULL for no censoring
cens_max
max censoring time, NULL for no censoring
mult_beta
enhancement factor for the beta coefficient to control signal-to-noise ratio
int
boolean, round the survival times to the next highest integer