tw.imputation {miceadds}R Documentation

Two-Way Imputation

Description

Two-way imputation using the simple method of Sijtsma and van der Ark (2003) and the MCMC based imputation of van Ginkel, van der Ark, Sijtsma and Vermunt (2007).

Usage

tw.imputation(data, integer=FALSE)

tw.mcmc.imputation(data, iter=100, integer=FALSE)

Arguments

data

Matrix of item responses corresponding to a scale

integer

A logical indicating whether imputed values should be integers. The default is FALSE.

iter

Number of iterations

Details

For persons p and items i, the two-way imputation is conducted by posing a linear model of tau-equivalent measurements:

X_{pi}=\theta_p + b_i + \varepsilon_{ij}

If the score X_{pi} is missing then it is imputed by

\hat{X}_{pi}=\tilde{X}_p + b_i

where \tilde{X}_p is the person mean of person p of the remaining items with observed responses.

The two-way imputation can also be seen as a scaling procedure to obtain a scale score which takes different item means into account.

Value

A matrix with original and imputed values

References

Sijtsma, K., & Van der Ark, L. A. (2003). Investigation and treatment of missing item scores in test and questionnaire data. Multivariate Behavioral Research, 38(4), 505-528. doi:10.1207/s15327906mbr3804_4

Van Ginkel, J. R., Van der Ark, A., Sijtsma, K., & Vermunt, J. K. (2007). Two-way imputation: A Bayesian method for estimating missing scores in tests and questionnaires, and an accurate approximation. Computational Statistics & Data Analysis, 51(8), 4013-4027. doi:10.1016/j.csda.2006.12.022

See Also

The two-way imputation method is also implemented in the TestDataImputation::Twoway function of the TestDataImputation package.

Examples

## Not run: 
#############################################################################
# EXAMPLE 1: Two-way imputation data.internet
#############################################################################

data(data.internet)
data <- data.internet

#***
# Model 1: Two-way imputation method of Sijtsma and van der Ark (2003)
set.seed(765)
dat.imp <- miceadds::tw.imputation( data )
dat.imp[ 278:281,]
  ##       IN9     IN10    IN11     IN12
  ##   278   5 4.829006 5.00000 4.941611
  ##   279   5 4.000000 4.78979 4.000000
  ##   280   7 4.000000 7.00000 7.000000
  ##   281   4 3.000000 5.00000 5.000000

#***
# Model 2: Two-way imputation method using MCMC
dat.imp <- miceadds::tw.mcmc.imputation( data, iter=3)
dat.imp[ 278:281,]
  ##       IN9     IN10     IN11     IN12
  ##   278   5 6.089222 5.000000 3.017244
  ##   279   5 4.000000 5.063547 4.000000
  ##   280   7 4.000000 7.000000 7.000000
  ##   281   4 3.000000 5.000000 5.000000

## End(Not run)

[Package miceadds version 3.17-44 Index]