Mplus
Tuesday
March 19, 2024
HOME ORDER CONTACT US CUSTOMER LOGIN MPLUS DISCUSSION
Mplus
Mplus at a Glance
General Description
Mplus Programs
Pricing
Version History
System Requirements
Platforms
Mplus Demo Version
Training
Mplus Web Talks
Short Courses
Short Course Videos
and Handouts
Web Training
Mplus YouTube Channel
Documentation
Mplus User's Guide
Mplus Diagrammer
Technical Appendices
Mplus Web Notes
FAQ
User's Guide Examples
Mplus Book
Mplus Book Examples
Mplus Book Errata
Analyses/Research
Mplus Examples
Papers
References
Special Mplus Topics
Bayesian SEM (BSEM)
Complex Survey Data
DSEM – MultiLevel Time Series Analysis
Exploratory SEM (ESEM)
Genetics
IRT
Measurement Invariance
and Alignment
Mediation Analysis
Missing Data
Mixture Modeling
Multilevel Modeling
Randomized Trials
RI-CLPM
RI-LTA
Structural Equation Modeling
Survival Analysis
How-To
Using Mplus via R
Mplus plotting using R
Chi-Square Difference
Test for MLM and MLR
Power Calculation
Monte Carlo Utility
Search
 
Mplus Website Updates
Mplus Privacy Policy
VPAT/508 Compliance

Using Mplus via R

A new R package is designed to automate three major aspects of latent variable modeling in Mplus:

  • Creating related groups of models
  • Running batches
  • Extracting and tabulating model parameters and test statistics.

The package is called MplusAutomation and is written by Michael Hallquist. The package is described in Hallquist, M. N. & Wiley, J.F. (2018). MplusAutomation: An R Package for Facilitating Large-Scale Latent Variable Analyses in Mplus. Structural Equation Modeling: A Multidisciplinary Journal, DOI: 10.1080/10705511.2017.140233

MplusAutomation is a package for R that seeks to optimize and streamline the use of Mplus for complex projects such as Monte Carlo simulation studies or the comparison of many models. In particular, MplusAutomation provides routines to 1) create and manage syntax for groups of related models; 2) automate the estimation of many models; and 3) provide tools to extract and compare model fit statistics, parameter estimates, and ancillary model outputs.

Four core routines support these aims: createModels, runModels, readModels, and compareModels. As of MplusAutomation v0.5, the package now supports the extraction of the majority of Mplus output sections as R data.frames and lists that can be readily sorted and compared. Sections extracted include model fit statistics, parameter estimates, confidence intervals, RESIDUALS, TECH1, TECH4, TECH11, TECH14, BPARAMETERS, and SAVEDATA. Fit statistics and parameter estimates for two models can be compared side-by-side using compareModels, which summarizes parameters that differ between models, parameters unique to each model, and chi-square difference tests for nested models (following the computation guidelines provided on www.statmodel.com).

The MplusAutomation package can be installed within R using the following call:

> install.packages("MplusAutomation")

Users are encouraged to post questions about the package to the MplusAutomation Google Group: https://groups.google.com/d/forum/mplusautomation with suggestions for new features and for troubleshooting problems related to the package.

Basic example of MplusAutomation used in Part 7 of the August 18 DSEM workshop.

Click here to go to the package.

Click here for documentation.

Related packages and papers

  • Konold, T.R. & Sanders, E.A. (2023). The SEM reliability paradox in a Bayesian framework. Structural Equation Modeling: A Multidisciplinary Journal. DOI: 10.1080/10705511.2023.2220915

  • Sanders, E.A. & Konold, T.R. (2023). X matters too: How the blended slope problem manifests differently in unilevel vs. multilevel models. Methodology, 2023, Vol. 19(1), 1–23, DOI: 10.5964/meth.9925

  • Serang, S., Jacobucci, R., Stegmann, G., Brandmaier, A. M., Culianos, D., & Grimm, K. J. (2021). Mplus Trees: Structural Equation Model Trees Using Mplus. Structural Equation Modeling, 28(1), 127-137. DOI: 10.1080/10705511.2020.1726179