Description Usage Arguments Value
View source: R/generateCovariates.R
Our simulations involve 10 covariates, which are either 1) 10 independent standard normal covariates, 2) 10 standard normal covariates that have pairwise correlations of 0.25, 3) 5 binary Bernouilli covariates with success probability 0.5 and 5 independent standard normal covariates, 4) 9 binary Bernouilli covariates with success probability 0.5 and 1 standard normal covariate, or 5) 10 binary Bernouilli covariates with success probability 0.5. These are abbreviated by "Ind Norm", "Corr Norm", "5 Bern", "9 Bern", and "10 Bern", respectively, and can also be referred to by their number (1-5).
1 | generateCovariates(cov_dist, n = 5000)
|
cov_dist |
The covariate distribution. An integer 1-5 or one of the following: 'Ind Norm', 'Corr Norm', '5 Bern', '9 Bern', '10 Bern' |
n |
The number of rows or observations to be generated |
Returns a data frame with 10 covariates of the specified distributions and n rows.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.