This function creates a complete dataset and then generates missingness
1 2 3 | generateData(mechanism, outcomeType, propMiss = 0.1, numSamp = 1000,
beta0 = 1, beta1 = 2, beta2 = 1, xmean = 0, xsd = 1,
errorsd = 0.1, rr = 5)
|
mechanism |
What is the missing data mechanism? |
outcomeType |
Is the outcome variable binary or continuous? |
propMiss |
Expected proportion of missingness. Defaults to 0.1. |
numSamp |
Number of observations in the sample. Defaults to 1000. |
beta0 |
Intercept. Defaults to 1. |
beta1 |
Treatment effect. Defaults to 2. |
beta2 |
Slope of auxiliary variable. Defaults to 1. |
xmean |
Mean of auxiliary variable. Defaults to 0. |
xsd |
Standard deviation of auxiliary variable. Defaults to 1. |
errorsd |
Standard deviation of error term. Defaults to 1. |
rr |
Risk ratio. Defaults to 5. Defaults to 5. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.