Function that simulates continuous variables. Any distribution function in R is supported.
sim_continuous(
k = NULL,
n,
p,
dist_fun,
var_type = c("level1", "level2", "level3", "single"),
...
)
Number of third level clusters.
Number of clusters or number of observations for single level
Number of within cluster observations for multilevel
A distribution function. This argument takes a quoted R distribution function (e.g. 'rnorm').
Variable type for the variable, must be either "level1", "level2", "level3", or "single"
Additional parameters to pass to the dist_fun argument.