Parses a group of Mplus model output files (.out extension) for model fit statistics.
At this time, the details extracted are fixed and include: Filename, InputInstructions, Title, Estimator,
LL, BIC, aBIC, AIC, AICC, Parameters, Observations, CFI, TLI, RMSEA_Estimate, RMSEA_90CI_LB, RMSEA_90CI_UB,
RMSEA_pLT05, ChiSqM_Value, ChiSqM_DF, ChiSq_PValue, BLRT_KM1LL, BLRT_PValue, BLRT_Numdraws)
. The
infrastructure is in place to allow for user-specified selection of summary statistics in future versions.
extractModelSummaries(target = getwd(), recursive = FALSE, filefilter)
Returns a data.frame
containing model fit statistics for all output files within directory
.
The data.frame
contains some of the following variables (depends on model type):
Title for the model, specified by the TITLE: command
Filename of the output file
Estimator used for the model (e.g., ML, MLR, WLSMV, etc.)
Log-likelihood of the model
Bayesian Information Criterion
Sample-Size-Adjusted BIC (Sclove, 1987)
Akaike's Information Criterion
Corrected AIC, based on Sugiura (1978) and recommended by Burnham & Anderson (2002)
Deviance Information Criterion. Available in ESTIMATOR=BAYES output.
Number of parameters estimated by the model
Estimated number of parameters in Bayesian output
The number of observations for the model (does not suppport multiple-groups analysis at this time)
Confirmatory Fit Index
Tucker-Lewis Index
Point estimate of root mean squared error of approximation
Lower bound of the 90% Confidence Interval around the RMSEA estimate.
Upper bound of the 90% Confidence Interval around the RMSEA estimate.
Probability that the RMSEA estimate falls below .05, indicating good fit.
Model chi-squared value
Model chi-squared degrees of freedom
Model chi-squared p value
H0 Scaling Correction Factor
Lower bound of 95% confidence interval for the difference between observed and replicated chi-square values
Upper bound of 95% confidence interval for the difference between observed and replicated chi-square values
Posterior predictive p-value
Prior Posterior Predictive P-Value
Number of requested bootstrap draws for TECH14.
Log-likelihood of the K-1 model (one less class) for the Bootstrapped Likelihood Ratio Test (TECH14).
Two times the log-likelihood difference of the models with K and K-1 classes (TECH14).
Difference in the number of parameters for models with K and K-1 classes (TECH14).
P-value of the Bootstrapped Likelihood Ratio Test (TECH14) testing whether the K class model is significantly better than K-1
The number of successful bootstrapped samples used in the Bootstrapped Likelihood Ratio Test
Standardized root mean square residual
For TYPE=TWOLEVEL output, standardized root mean square residual for between level
For TYPE=TWOLEVEL output, standardized root mean square residual for within level
Weighted root mean square residual
Baseline (unstructured) chi-squared value
Baseline (unstructured) chi-squared degrees of freedom
Baseline (unstructured) chi-squared p value
For TYPE=EFA output, the number of factors
TECH11: Number of initial stage random starts for k-1 model
TECH11: Number of final stage optimizations for k-1 model
TECH11: Log-likelihood of the K-1 model used for the Vuong-Lo-Mendell-Rubin LRT
TECH11: 2 * Log-likelihood Difference of K-class vs. K-1-class model for the Vuong-Lo-Mendell-Rubin LRT
TECH11: Difference in number of parameters between K-class and K-1-class model for the Vuong-Lo-Mendell-Rubin LRT
TECH11: Vuong-Lo-Mendell-Rubin LRT mean
TECH11: Vuong-Lo-Mendell-Rubin LRT standard deviation
TECH11: Vuong-Lo-Mendell-Rubin LRT p-value
TECH11: Lo-Mendell-Rubin Adjusted LRT value
TECH11: Lo-Mendell-Rubin Adjusted LRT p-value
the directory containing Mplus output files (.out) to parse OR the single output file to be parsed. Defaults to the current working directory. Example: "C:/Users/Michael/Mplus Runs"
optional. If TRUE
, parse all models nested in
subdirectories within directory
. Defaults to FALSE
.
a Perl regular expression (PCRE-compatible) specifying particular
output files to be parsed within directory
. See regex
or
http://www.pcre.org/pcre.txt for details about regular expression syntax.
Michael Hallquist
regex
, runModels
, readModels
if (FALSE) {
allExamples <- extractModelSummaries(
"C:/Program Files/Mplus/Mplus Examples/User's Guide Examples")
}
Run the code above in your browser using DataLab