imp.mix | R Documentation |
This function, when used with da.mix
or
dabipf.mix
, can be
used to create proper multiple imputations of missing data under
the general location model with or without restrictions.
imp.mix(s, theta, x)
s |
summary list of an incomplete data matrix |
theta |
value of the parameter under which the missing data are to be
randomly imputed. This is a parameter list such as one created
by |
x |
the original data matrix used to create the summary list |
This function is essentially the I-step of data augmentation.
a matrix of the same form as x
, but with all missing values filled in
with simulated values drawn from their predictive distribution given
the observed data and the specified parameter.
The random number generator seed must be set at least once by the
function rngseed
before this function can be used.
Schafer, J. L. (1996) Analysis of Incomplete Multivariate Data. Chapman & Hall, Chapter 9.
prelim.mix
, da.mix
,
dabipf.mix
, rngseed
data(stlouis) s <- prelim.mix(stlouis,3) # do preliminary manipulations thetahat <- em.mix(s) # ML estimate for unrestricted model rngseed(1234567) # set random number generator seed newtheta <- da.mix(s,thetahat,steps=100) # data augmentation ximp <- imp.mix(s, newtheta, stlouis) # impute under newtheta
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.