Open jpritikin opened 1 day ago
If I use phenom ~ c(0,NA)*1
then does what is expected. The parameter is fixed in group 1 and free in group 2.
Thanks for the reports, and I will take a look at the others soon. For this one, I believe that the lavaan parser does not like parameter labels mixed with numerical constraints inside c(). You can see this by running
fit2 <- lavaan(spec, data=combinedData, ordered=AbsItemNames, group="group", allow.empty.cell=TRUE, cat.wls.w=FALSE)
lavInspect(fit2, 'free')
It produces a bunch of warnings, but the nonzero entries in the output of the second command signify free parameters. The $psi$alpha and $pm$alpha matrices show whether or not your phenom means are free.
If you want parameter labels and one mean fixed to 0, I think the line below would work. Though then a different warning comes from lavaan, that I believe can be ignored:
phenom ~ c(0,NA)*1 + c(psM,pmM)*1
lavaan 0.6-19 (cran), blavaan 0.5-6.1311 (via github)
The line
phenom ~ c(0,pmM)*1
seems to not work correctly? The intercept is set topmM
in both groups.Data:
pm.csv psi.csv