This class extends the '>lavaanList class, created by
fitting a lavaan model to a list of data sets. In this case, the list of
data sets are multiple imputations of missing data.
# S4 method for lavaan.mi
show(object)# S4 method for lavaan.mi
summary(object, se = TRUE, ci = FALSE, level = 0.95,
standardized = FALSE, rsquare = FALSE, fmi = FALSE, header = TRUE,
scale.W = TRUE, asymptotic = FALSE, add.attributes = TRUE)
# S4 method for lavaan.mi
nobs(object, total = TRUE)
# S4 method for lavaan.mi
coef(object, type = "free", labels = TRUE)
# S4 method for lavaan.mi
vcov(object, type = c("pooled", "between", "within",
"ariv"), scale.W = TRUE)
# S4 method for lavaan.mi
anova(object, h1 = NULL, test = c("D3", "D2", "D1"),
pool.robust = FALSE, scale.W = FALSE, asymptotic = FALSE,
constraints = NULL, indices = FALSE, baseline.model = NULL,
method = "default", A.method = "delta", scaled.shifted = TRUE,
H1 = TRUE, type = "Chisq")
# S4 method for lavaan.mi
fitMeasures(object, fit.measures = "all",
baseline.model = NULL)
# S4 method for lavaan.mi
fitmeasures(object, fit.measures = "all",
baseline.model = NULL)
# S4 method for lavaan.mi
fitted(object)
# S4 method for lavaan.mi
fitted.values(object)
# S4 method for lavaan.mi
residuals(object, type = c("raw", "cor"))
# S4 method for lavaan.mi
resid(object, type = c("raw", "cor"))
An object of class lavaan.mi
See
parameterEstimates.
logical indicating whether to include the Fraction Missing
Information (FMI) for parameter estimates in the summary output
(see Value section).
logical. If TRUE (default), the vcov
method will calculate the pooled covariance matrix by scaling the
within-imputation component by the ARIV (see Enders, 2010, p. 235,
for definition and formula). Otherwise, the pooled matrix is calculated
as the weighted sum of the within-imputation and between-imputation
components (see Enders, 2010, ch. 8, for details). This in turn affects
how the summary method calcualtes its pooled standard errors, as
well as the Wald test (anova(..., test = "D1")).
logical. If FALSE (typically a default, but
see Value section for details using various methods), pooled
tests (of fit or pooled estimates) will be F or t
statistics with associated degrees of freedom (df). If
TRUE, the (denominator) df are assumed to be sufficiently
large for a t statistic to follow a normal distribution, so it
is printed as a z statisic; likewise, F times its
numerator df is printed, assumed to follow a \(\chi^2\)
distribution.
logical (default: TRUE) indicating whether the
nobs method should return the total sample size or (if
FALSE) a vector of group sample sizes.
The meaning of this argument varies depending on which method it
it used for. Find detailed descriptions in the Value section
under coef, vcov, residuals, and anova.
logical indicating whether the coef output should
include parameter labels. Default is TRUE.
An object of class lavaan.mi in which object is
nested, so that their difference in fit can be tested using
anova (see Value section for details).
character indicating the method used to pool model-fit or
model-comparison test statistics:
"D3": The default test ("D3", or any of
"mr", "Meng.Rubin", "likelihood", "LRT") is a pooled
likeliehood-ratio test (see Enders, 2010, ch. 8).
test = "mplus" implies "D3" and asymptotic =
TRUE (see Asparouhov & Muthen, 2010). When using a non-likelihood
estimator (e.g., DWLS for categorical outcomes), "D3" is
unavailable, so the default is changed to "D2".
"D2": Returns a pooled test statistic, as described by
Li, Meng, Raghunathan, & Rubin (1991) and Enders (2010, chapter 8).
Aliases include "lmrr", "Li.et.al", "pooled.wald").
"D1": Returns a Wald test calculated for constraints on
the pooled point estimates, using the pooled covariance matrix of
parameter estimates; see lavTestWald for
details. h1 is ignored when test = "D1", and
constraints is ignored when test != "D1". The
scale.W argument is passed to the vcov method (see
Value section for details).
logical. Ignored unless test = "D2" and a
robust test was requested. If pool.robust = TRUE, the robust test
statistic is pooled, whereas pool.robust = FALSE will pool
the naive test statistic (or difference statistic) and apply the average
scale/shift parameter to it (unavailable for mean- and variance-adjusted
difference statistics, so pool.robust will be set TRUE).
If test = "D2" and pool.robust = TRUE, further options
can be passed to lavTestLRT (see below).
See lavTestWald.
logical, or character vector naming fit indices
to be printed with test of model fit. Ignored if (!is.null(h1)).
See description of anova in Value section for details.
See lavTestLRT.
See fitMeasures.
signature(object = "lavaan.mi", type = "free", labels = TRUE):
See '>lavaan. Returns the pooled point estimates (i.e.,
averaged across imputed data sets; see Rubin, 1987).
signature(object = "lavaan.mi", scale.W = TRUE,
type = c("pooled","between","within","ariv")): By default, returns the
pooled covariance matrix of parameter estimates (type = "pooled"),
the within-imputations covariance matrix (type = "within"), the
between-imputations covariance matrix (type = "between"), or the
average relative increase in variance (type = "ariv") due to missing
data.
signature(object = "lavaan.mi"): See
'>lavaan. Returns model-implied moments, evaluated at the
pooled point estimates.
signature(object = "lavaan.mi"):
alias for fitted.values
signature(object = "lavaan.mi", type = c("raw","cor")):
See '>lavaan. By default (type = "raw"), returns
the difference between the model-implied moments from fitted.values
and the pooled observed moments (i.e., averaged across imputed data sets).
Standardized residuals are also available, using Bollen's
(type = "cor" or "cor.bollen") or Bentler's
(type = "cor.bentler") formulas.
signature(object = "lavaan.mi", type = c("raw","cor")):
alias for residuals
signature(object = "lavaan.mi", total = TRUE): either
the total (default) sample size or a vector of group sample sizes
(total = FALSE).
signature(object = "lavaan.mi", h1 = NULL,
test = c("D3","D2","D1"), pool.robust = FALSE, scale.W = TRUE,
asymptotic = FALSE, constraints = NULL, indices = FALSE, baseline.model = NULL,
method = "default", A.method = "delta", H1 = TRUE, type = "Chisq"):
Returns a test of model fit if h1 is NULL, or a test
of the difference in fit between nested models if h1 is another
lavaan.mi object, assuming object is nested in h1. If
asymptotic, the returned test statistic will follow a \(\chi^2\)
distribution in sufficiently large samples; otherwise, it will follow an
F distribution. If a robust test statistic is detected in the
object results (it is assumed the same was requested in h1,
if provided), then asymptotic will be set to TRUE and the
pooled test statistic will be scaled using the average scaling factor (and
average shift parameter or df, if applicable) across imputations
(unless pool.robust = FALSE and test = "D2"; see below).
When indices = TRUE and is.null(h1), popular indices of
approximate fit (CFI, TLI/NNFI, RMSEA with CI, and SRMR) will be returned
for object; see fitMeasures for more details.
Specific indices can be requested with a character vector (any of
"mfi", "rmsea", "gammaHat", "rmr", "srmr", "cfi", "tli", "nnfi",
"rfi", "nfi", "pnfi", "ifi", "rni"), or all available indices will be
returned if indices = "all". Users can specify a custom
baseline.model, also fit using runMI, to calculate
incremental fit indices (e.g., CFI, TLI). If baseline.model = NULL,
the default independence model will be used.
signature(object = "lavaan.mi",
fit.measures = "all", baseline.model = NULL): arguments are consistent
with lavaan's fitMeasures. This merely calls the
anova method described above, with indices = fit.measures
and baseline.model = baseline.model, and default values for the
remaining arguments. The user has more control (e.g., over pooling methods)
using anova directly.
alias for fitMeasures.
signature(object = "lavaan.mi"): returns a message about
convergence rates and estimation problems (if applicable) across imputed
data sets.
signature(object = "lavaan.mi", se = TRUE, ci = FALSE,
level = .95, standardized = FALSE, rsquare = FALSE, fmi = FALSE,
scale.W = FALSE, asymptotic = FALSE, add.attributes = TRUE): see
parameterEstimates for details.
By default, summary returns pooled point and SE
estimates, along with t test statistics and their associated
df and p values. If ci = TRUE, confidence intervales
are returned with the specified confidence level (default 95% CI).
If asymptotic = TRUE, z instead of t tests are
returned. standardized solution(s) can also be requested by name
("std.lv" or "std.all") or both are returned with TRUE.
R-squared for endogenous variables can be requested, as well as the
Fraction Missing Information (FMI) for parameter estimates. By default, the
output will appear like lavaan's summary output, but if
add.attributes = FALSE, the returned data.frame will resemble
the parameterEstimates output. The scale.W argument is
passed to vcov (see description above).
coefListlist of estimated coefficients in matrix format (one
per imputation) as output by lavInspect(fit, "est")
GLISTpooled list of coefficients in GLIST format
miListlist of modification indices output by
modindices
seedinteger seed set before running imputations
lavListCallcall to lavaanList used to fit the
model to the list of imputed data sets in @DataList, stored as a
list of arguments
imputeCallcall to imputation function (if used), stored as a
list of arguments
convergencelist of logical vectors indicating whether,
for each imputed data set, (1) the model converged on a solution, (2)
SEs could be calculated, (3) the (residual) covariance matrix of
latent variables (\(\Psi\)) is non-positive-definite, and (4) the residual
covariance matrix of observed variables (\(\Theta\)) is
non-positive-definite.
lavaanList_slotsAll remaining slots are from
'>lavaanList, but runMI only populates a
subset of the list slots, two of them with custom information:
DataListThe list of imputed data sets
SampleStatsListList of output from
lavInspect(fit, "sampstat") applied to each fitted
model
ParTableListvcovListtestListAsparouhov, T., & Muthen, B. (2010). Chi-square statistics with multiple imputation. Technical Report. Retrieved from www.statmodel.com
Enders, C. K. (2010). Applied missing data analysis. New York, NY: Guilford.
Li, K.-H., Meng, X.-L., Raghunathan, T. E., & Rubin, D. B. (1991). Significance levels from repeated p-values with multiply-imputed data. Statistica Sinica, 1(1), 65--92. Retrieved from http://www.jstor.org/stable/24303994
Meng, X.-L., & Rubin, D. B. (1992). Performing likelihood ratio tests with multiply-imputed data sets. Biometrika, 79(1), 103--111. Retrieved from http://www.jstor.org/stable/2337151
Rubin, D. B. (1987). Multiple imputation for nonresponse in surveys. New York, NY: Wiley.
# NOT RUN {
## See ?runMI help page
# }
Run the code above in your browser using DataLab