View source: R/umxSummary.MxModel.R
| umxSummary.MxModel | R Documentation |
Report the fit of a model in a compact form suitable for a journal. It reports parameters in a markdown or html table (optionally standardized), and fit indices RMSEA (an absolute fit index, comparing the model to a perfect model) and CFI and TLI (incremental fit indices comparing a model with the worst fit).
## S3 method for class 'MxModel'
umxSummary(
model,
refModels = NULL,
std = FALSE,
digits = 2,
report = c("markdown", "html"),
means = TRUE,
residuals = TRUE,
uncertainty = c("SE", "MLR", "CI", "none"),
filter = c("ALL", "NS", "SIG"),
RMSEA_CI = FALSE,
SE = TRUE,
matrixAddresses = FALSE,
...
)
model |
The |
refModels |
Saturated models if needed for fit indices (see example below: If NULL will be computed on demand. If FALSE will not be computed. |
std |
If TRUE, model is standardized (Default FALSE, NULL means "don't show"). |
digits |
How many decimal places to report (Default 2) |
report |
If "html", then show results in browser (default = "markdown") |
means |
Whether to include means in the summary (TRUE) |
residuals |
Whether to include residuals in the summary (TRUE) |
uncertainty |
What type of uncertainty/inference packaging to report: |
filter |
whether to show significant paths (SIG) or NS paths (NS) or all paths (ALL) |
RMSEA_CI |
Whether to compute the CI on RMSEA (Defaults to FALSE) |
SE |
Deprecated. Please use |
matrixAddresses |
Whether to show "matrix address" columns (Default = FALSE) |
... |
Other parameters to control model summary |
umxSummary alerts you when model fit is worse than accepted criterion (TLI >= .95 and RMSEA <= .06; (Hu & Bentler, 1999; Yu, 2002).
Note: For some (multi-group) models, you will need to fall back on summary()
Robust inference (uncertainty = "MLR")
This option means engine-appropriate robust inference, not one sandwich formula for every fit type:
ML / FIML (raw continuous): casewise score sandwich SEs via OpenMx::imxRobustSE(), plus robust CFI/TLI/RMSEA via xmu_robust_ML_fit() (Yuan-Bentler / Brosseau-Liard & Savalei scaling).
WLS / DWLS / ULS: do not use the ML casewise sandwich. Parameter SEs are the usual WLS/GMM moment sandwich already returned by OpenMx (W, \Delta, \Gamma). Robust CFI/TLI/RMSEA are applied when output$implied_jacobian is present via xmu_robust_WLS_fit() (Satorra-Bentler 2010 for continuous WLS; Savalei 2021 catML for ordinal WLS). A statistical note states that SEs are WLS asymptotic (moment sandwich).
Robust Fit Statistics for ML
Standard Maximum Likelihood (ML) is powerful and efficient, with chi2, CFI, TLI, and RMSEA measures of fit. Non-normality and heteroscedasticity distort the sampling distribution of the scores and the ML test statistic itself, necessitating changes to SEs and fit statistics. For ML, uncertainty = "MLR" implements the sandwich estimator for SEs and MLR-style fit scaling (Yuan-Bentler / Savalei 2018-style robust indices).
Robust Fit Statistics for WLS/DWLS (The GenomicMx Ecosystem)
Simulation work shows CFI/TLI behave differently under DWLS/WLS than under ML
(Shi et al., 2020): incremental indices use an independence baseline under the
weight matrix, so conventional cutoffs (e.g. CFI > 0.95) break down for continuous WLS
and Genomic SEM. Prefer SRMR and residual inspection for absolute fit; use
umxCompare() for nested tests. See ?umxCompare for the full guidance.
Implementation: when a Jacobian is available, umxSummary routes WLS models
through xmu_robust_WLS_fit() (independence baseline + trace scaling). Parameter SEs
remain the OpenMx WLS moment sandwich (see uncertainty = "MLR" above). Robust
CFI/TLI/RMSEA are reported for continuous WLS but should be treated as descriptive
(no Hu-Bentler cutoffs). Genomic SEM has the same rule, with even less trust in RMSEA
under bookkeeping N.
Two statistic families (by design). WLS output separates omnibus testing from fit indices:
Displayed \chi^2 and p - Satorra-Bentler (2010) scaled WLS test when robust fit succeeds (continuous and ordinal).
Displayed CFI, TLI, RMSEA - robust/scaled indices; interpretation depends on continuous vs ordinal (below).
Continuous WLS (all manifests numeric): SB (2010) scaled pipeline
(\chi^2 = F/c from output$fit, same Chi as umxCompare() when Jacobians
are present). Saturated residual df (ChiDoF = 0): Chi = 0, p = NA, CFI = TLI = 1,
RMSEA = 0 (not NA). Printed note: no conventional cutoffs; prefer SRMR; nested
Strict SB via umxCompare().
Ordinal / categorical WLS (at least one ordered/factor on raw data): robust CFI/TLI/RMSEA use Savalei (2021) catML (Categorical Maximum Likelihood) corrections; Hu & Bentler (1999) cutoffs (CFI > .95, RMSEA < .06) apply to these robust indices. Displayed \chi^2/p remain SB-scaled WLS omnibus tests.
catML (Categorical Maximum Likelihood): Evaluates parameter estimates inside a Maximum Likelihood correlation scaffold to obtain non-inflated fit indices for ordinal data.
c_{\text{model}} and c_{\text{null}}: Mean-and-variance scaling correction multipliers for model and baseline discrepancies (values near 1.0 indicate sample sampling variability matches standard ML expectations; values > 1.0 adjust for categorical overdispersion).
Suggested Manuscript Copy: "Model fit was evaluated using DWLS with robust categorical ML fit indices (Savalei, 2021; CFI = X.XX, RMSEA = X.XX)."
Requires implied_jacobian after mxRun on WLS. If robust computation fails, falls back to OpenMx summary() with a note.
CIs and Identification This function uses the standard errors reported by OpenMx to produce the CIs you see in umxSummary. These are used to derive confidence intervals based on the formula 95%CI = estimate +/- 1.96*SE.
Sometimes SEs appear NA. This may reflect a model which is not identified (see http://davidakenny.net/cm/identify.htm).
This can include empirical under-identification - for instance two factors
that are essentially identical in structure. Use OpenMx::mxCheckIdentification() to check identification.
Solutions: If there are paths estimated at or close to zero, this suggests that fixing one or two of these to zero may fix the standard error calculation.
If factor loadings can flip sign and provide identical fit, this creates another form of under-identification and can break confidence interval estimation. Solution: Fixing a factor loading to 1 and estimating factor variances can help here.
parameterTable returned invisibly, if estimates requested
Hu, L., & Bentler, P. M. (1999). Cutoff criteria for fit indexes in covariance structure analysis: Conventional criteria versus new alternatives. Structural Equation Modeling, 6, 1-55.
Satorra, A., & Bentler, P. M. (2010). Ensuring positiveness of the scaled difference chi-square test statistic. Psychometrika, 75(2), 243-248.
Satorra, A. and Bentler P. M. (1994). Corrections to test statistics and standard errors in covariance structure analysis. Latent variables analysis: Applications for developmental research. A. von Eye and C. C. Clogg, Sage: 399-419.
Savalei, V. (2018). On the computation of the RMSEA and CFI from the mean-and-variance corrected test statistic with nonnormal data in SEM. Multivariate Behavioral Research, 53(3), 419–429.
Savalei, V. (2021). Improving fit indices in SEM with categorical data. Multivariate Behavioral Research, 56(3), 390–407.
Brosseau-Liard, P. E., & Savalei, V. (2012). Adjusting incremental fit indices for nonnormality. Multivariate Behavioral Research, 47(5), 647–677.
Yu, C.Y. (2002). Evaluating cutoff criteria of model fit indices for latent variable models with binary and continuous outcomes. University of California, Los Angeles. Retrieved from https://www.statmodel.com/download/Yudissertation.pdf
Yuan, K.-H. and P. M. Bentler (2000). "5. Three Likelihood-Based Methods for Mean and Covariance Structure Analysis with Nonnormal Missing Data." Sociological Methodology 30(1): 165-200.
umxRAM(), xmu_robust_WLS_fit()
Other Summary functions:
umxSummaryACEcov(),
umxSummaryCP(),
umxSummaryGxE(),
umxSummaryIP(),
umxSummaryMRDoC()
## Not run:
require(umx)
data(demoOneFactor)
manifests = names(demoOneFactor)
m1 = umxRAM("One Factor", data = demoOneFactor, type = "cov",
umxPath("G", to = manifests),
umxPath(var = manifests),
umxPath(var = "G", fixedAt = 1)
)
umxSummary(m1, std = TRUE)
# output as latex
umx_set_table_format("latex")
umxSummary(m1, std = TRUE)
umx_set_table_format("markdown")
# output as raw
umxSummary(m1, std = FALSE)
# switch to a raw data model
m1 = umxRAM("One Factor", data = demoOneFactor[1:100, ],
umxPath("G", to = manifests),
umxPath(v.m. = manifests),
umxPath(v1m0 = "G")
)
umxSummary(m1, std = TRUE, filter = "NS")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.