This function runs a simulations fitting models using various methods of handling missing data. Passes back an array of model parameter values.
1 2 3 | runSimulation(numSim = 1000, m = 5, mechanism = "mcar", propMiss = 0.1,
numSamp = 1000, beta0 = 1, beta1 = 2, beta2 = 1, xmean = 0,
xsd = 1, errorsd = 0.5, rr = 5, outcomeType)
|
numSim |
Number of simulations. Defaults to 1000. |
m |
Number of imputations. Defaults to 5. |
mechanism |
What is the missing data mechanism? Defaults to mcar. |
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 0.5. |
rr |
Risk ratio. Defaults to 5. Defaults to 5. |
outcomeType |
Is the outcome variable binary or continuous? |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.