SCTModel2 <- '
RBehF1=~BF1_RAV+BF2_RAV+BF3_RAV+BF4_RAV+BF6_RAV+BF7_RAV
# direct effect
RaterJobSat ~ c*RBehF1
# mediator
RaterReward ~ a*RBehF1
RaterJobSat ~ b*RaterReward
# indirect effect (a*b)
indirect := a*b
# total effect
total := c + (a*b)
RBehF1~~RaterJobSat
RBehF1~~RaterReward
RaterReward~~RaterJobSat
'
SCT1fit2<-sem(SCTModel2, data = SMBI_Alldata, test = "bollen.stine", se="boot", bootstrap = 5000)
summary(SCT1fit2, standardized = T, fit.measures = T, rsq = T)
boot.fit2 <- parameterEstimates(SCT1fit2, boot.ci.type="bca.simple",level=0.95, ci=TRUE,standardized = FALSE)
boot.fit2
semPaths(SCT1fit2, "stand", residuals = FALSE, intercepts = FALSE, fixed = TRUE, what = "paths", unCol = "black", rotation = 2, edge.label.cex = 0.7, asize = 1.1, style = "lisrel", layout = "tree", curveAdjacent = TRUE, nCharNodes=0, sizeMan2=3, sizeMan=14, sizeLat = 12, sizeLat2 = 6, label.prop=1, label.norm = "00000000000000000", curve=3, cardinal = TRUE, layoutSplit = FALSE)
semPaths(SCT1fit2)
The behaviour variable has 6 latent factors,
how I would add the error term, and why this is important?