I am using lavaan package to run confirmatory analysis and continue to get the following error
Error in lavaan::lavaan(model = model1, data = STR_Historical_Data, model.type = "cfa", : lavaan ERROR: missing observed variables in dataset: ..constant..
I successfully ran the first line of code and created the model1 in my values. The error shows after I run the fit <- cfa(model1, data = STR_Historical_Data)
#CFA Model#
model1 <- '
ROCI =~ v4+v6+v7+v8+v11+v17+v18+v19+v20+v22+v24+v26+v29+31+v32'
fit <- cfa(model1, data = STR_Historical_Data)
summary(fit1, fitmeasures=TRUE)