CFA | R Documentation |
EGA
or hierEGA
StructureVerifies the fit of the structure suggested by
EGA
or by hierEGA
using
confirmatory factor analysis
CFA(ega.obj, data, estimator, plot.CFA = TRUE, layout = "spring", ...)
ega.obj |
An |
data |
Matrix or data frame. Should consist only of variables to be used in the analysis |
estimator |
The estimator used in the confirmatory factor analysis.
'WLSMV' is the estimator of choice for ordinal variables.
'ML' or 'WLS' for interval variables.
See |
plot.CFA |
Logical. Should the CFA structure with its standardized loadings be plot? Defaults to TRUE |
layout |
Layout of plot (see |
... |
Arguments passed to |
Returns a list containing:
fit |
Output from |
summary |
Summary output from |
fit.measures |
Fit measures: chi-squared,
degrees of freedom, p-value, CFI, RMSEA, GFI, and NFI.
Additional fit measures can be applied using the
|
Hudson F. Golino <hfg9s at virginia.edu>
Demonstrative use
Christensen, A. P., Gross, G. M., Golino, H., Silvia, P. J., & Kwapil, T. R. (2019).
Exploratory graph analysis of the Multidimensional Schizotypy Scale.
Schizophrenia Research, 206, 43-51.
Initial implementation
Golino, H., & Epskamp, S. (2017).
Exploratory graph analysis: A new approach for estimating the number of dimensions in psychological research.
PLoS ONE, 12, e0174035.
# Load data
wmt <- wmt2[,7:24]
## Not run:
# Estimate EGA
ega.wmt <- EGA(
data = wmt,
plot.EGA = FALSE # No plot for CRAN checks
)
# Fit CFA model to EGA results
cfa.wmt <- CFA(
ega.obj = ega.wmt, estimator = "WLSMV",
plot.CFA = FALSE, # No plot for CRAN checks
data = wmt
)
# Additional fit measures
lavaan::fitMeasures(cfa.wmt$fit, fit.measures = "all")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.