# Load data
wmt <- wmt2[,7:24]
if (FALSE) {
# 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")}
Run the code above in your browser using DataLab