This function is a wrapper for the functions mplusObject and mplusModeler. Using this function requires 'Mplus' to be installed.

estimate_mplus(x, ...)

Arguments

x

An object of class tidy_sem.

...

Additional parameters passed to mplusObject and mplusModeler. These arguments are matched to the correct function by name. The arguments rdata, and MODEL cannot be edited, as they are determined from the tidy_sem object.

Value

An object of class mplusObject.

Details

The arguments dataout, modelout, and run are optional. If these are not specified, the model will be run in tempdir.

Examples

#> Version: 1.0.0 #> We work hard to write this free software. Please help us get credit by citing: #> #> Hallquist, M. N. & Wiley, J. F. (2018). MplusAutomation: An R Package for Facilitating Large-Scale Latent Variable Analyses in Mplus. Structural Equation Modeling, 25, 621-638. doi: 10.1080/10705511.2017.1402334. #> #> -- see citation("MplusAutomation").
model <- tidy_sem(iris, "\\.") model <- measurement(model) if(mplusAvailable() == 0){ estimate_mplus(model) }
#> v Mplus is available.
#> Estimated using ML #> Number of obs: 150, number of (free) parameters: 13 #> #> Model: Chi2(df = 1) = 2.322, p = 0.1276 #> Baseline model: Chi2(df = 6) = 722.206, p = 0 #> #> Fit Indices: #> #> CFI = 0.998, TLI = 0.989, SRMR = 0.014 #> RMSEA = 0.094, 90% CI [0, 0.259], p < .05 = 0.197 #> AIC = 788.151, BIC = 827.289 #> NULL