multipleEI: Generate Multiple Edit-imputed Datasets

Description Usage Arguments Details Value See Also Examples

View source: R/RunningMCMC.R

Description

multipleEI returns m multiple edit-imputed datasets.

Usage

1
multipleEI(model.obj, n.burnin, m, int.btw.EI, show.iter=TRUE)

Arguments

model.obj

Rcpp_bei model-object generated from createModel.

n.burnin

number of burn in iterations.

m

number of multiple edit-imputed datasets.

int.btw.EI

interval (number of iterations) between EI datasets.

show.iter

logical specifying if the iteration number of burning-in is displayed.

Details

The total number of MCMC iterations is (n.burnin + m * int.btw.EI). Please see the example in the demo folder for more detailed explanation.

Value

array of (m, n, p) dimension where m is the number of edit-imputed data sets, n is the number of records and p is the number of variables.

See Also

createModel

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
data(SimpleEx)
data1 = readData(SimpleEx$D.obs, SimpleEx$Ratio.edit, NULL, SimpleEx$Balance.edit)
# model1 = createModel(data1, 15)

## get 3 edit-imputed data from MCMC by storing every 100 iterations after 50 burn-in

# result1 = multipleEI(model1, n.burnin=50, m=3, int.btw.EI=100)

# dim(result1) 
## [1]   3 1000   4  
## m=3 Edit-imputed datasets of n=1000 records with p=4 variables

EditImputeCont documentation built on March 26, 2020, 7:15 p.m.