# NOT RUN {
# Load data
wmt <- wmt2[,7:24]
# }
# NOT RUN {
# Estimate EGA
ega.wmt <- EGA(data = wmt)
# }
# NOT RUN {
# Fit CFA model to EGA results
cfa.wmt <- CFA(ega.obj = ega.wmt, estimator = 'WLSMV', plot.CFA = TRUE, data = wmt)
# Additional fit measures
lavaan::fitMeasures(cfa.wmt$fit, fit.measures = "all")
# Load data
intel <- intelligenceBattery[,8:66]
# }
# NOT RUN {
# Estimate EGA
ega.intel <- EGA(data = intel)
# Fit CFA model to EGA results
cfa.intel <- CFA(ega.obj = ega.intel, estimator = 'WLSMV', plot.CFA = TRUE,
data = intel)
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab