simulation {BinNor} | R Documentation |
Repeats the data generation process in a simulation scheme
Description
Simulates many versions of mixed data, and reports averaged proportion, mean, variance and correlation estimates across replications.
Usage
simulation(seed = NULL, nsim, no.rows, no.bin, no.nor,
mean.vec.nor = NULL, var.nor = NULL, prop.vec.bin = NULL,
corr.vec = NULL, corr.mat = NULL, continue.with.warning = TRUE)
Arguments
seed |
A seed value for the random number generator. Seed value will be randomly generated unless specified. |
nsim |
Number of simulation runs. |
no.rows |
Number of rows. |
no.bin |
Number of binary variables |
no.nor |
Number of normal variables |
prop.vec.bin |
Probability vector for binary variables |
mean.vec.nor |
Vector of means for normal variables |
var.nor |
Vector of variances for normal variables |
corr.vec |
Vector of elements below the diagonal of correlation matrix ordered columnwise |
corr.mat |
Specified correlation matrix |
continue.with.warning |
TRUE to proceed with the nearest positive definite |
See Also
compute.sigma.star
, jointly.generate.binary.normal
Examples
simulation(nsim=10, no.rows=100, no.bin=2, no.nor=2,
mean.vec.nor=c(3,1), var.nor=c(4,2), prop.vec.bin=c(0.4,0.7),
corr.vec=c(0.16,0.04,0.38,0.14,0.47,0.68), corr.mat=NULL)
[Package BinNor version 2.3.3 Index]