multipleSyn {synMicrodata}R Documentation

Generate synthetic micro datasets

Description

Generate synthetic micro datasets using a hierarchically coupled mixture model with local dependence (HCMM-LC).

Usage

multipleSyn(data_obj, model_obj, n_burnin, m, interval_btw_Syn, show_iter = TRUE)

## S3 method for class 'synMicro_object'
print(x, ...)

Arguments

data_obj

data object produced by readData.

model_obj

model object produced by createModel.

n_burnin

size of burn-in.

m

number of synthetic micro datasets to be generated.

interval_btw_Syn

interval between MCMC iterations for generating synthetic micro datasets.

show_iter

logical value. If TRUE, multipleSyn will print history of (r,s,k) components on console.

x

object of class synMicro_object; a result of a call to multipleSyn().

...

further arguments passed to or from other methods.

Value

multipleSyn returns a list of the following conmponents:

synt_data

list of m synthetic micro datasets.

comp_mat

list of matrices of the mixture component indices.

orig_data

original dataset.

References

Murray, J. S. and Reiter, J. P. (2016). Multiple imputation of missing categorical and continuous values via Bayesian mixture models with local dependence. Journal of the American Statistical Association, 111(516), pp.1466-1479.

See Also

readData, createModel, plot.synMicro_object

Examples

## preparing to generate synthetic datsets
dat_obj <- readData(Y_input = iris[,1:4],
                    X_input = data.frame(Species = iris[,5]))
mod_obj <- createModel(dat_obj, max_R_S_K=c(30,50,20))

## generating synthetic datasets
res_obj <- multipleSyn(dat_obj, mod_obj, n_burnin = 100, m = 5, 
                       interval_btw_Syn = 50, show_iter = FALSE)

print(res_obj)

[Package synMicrodata version 2.0.0 Index]