Hi.

I am running a bivariate moderation model and would like to set some constraints in order to test for some nonlinear effects. I am struggling though with adding new algebras into submodels (with subsequent equating them). Let's say that I specify

pathAm <- mxMatrix(name = "am", type = "Lower", nrow = nv, ncol = nv, free=T, labels = c("amM","amC","amU"), values=pathVal) pathCm <- mxMatrix(name = "cm", type = "Lower", nrow = nv, ncol = nv, free=T, labels = c("cmM","cmC","cmU"), values=pathVal) pathEm <- mxMatrix(name = "em", type = "Lower", nrow = nv, ncol = nv, free=T, labels = c("emM","emC","emU"), values=pathVal) pathAf <- mxMatrix(name = "af", type = "Lower", nrow = nv, ncol = nv, free=T, labels = c("afM","afC","afU"), values=pathVal) pathCf <- mxMatrix(name = "cf", type = "Lower", nrow = nv, ncol = nv, free=T, labels = c("cfM","cfC","cfU"), values=pathVal) pathEf <- mxMatrix(name = "ef", type = "Lower", nrow = nv, ncol = nv, free=T, labels = c("efM","efC","efU"), values=pathVal)

and so on in the model

`CholACEModel`

(with MZM, DZM, MZF and DZF as submodels).
I would like to introduce certain constraints and test the submodels against `CholACEModel`

:

amC/amM=cmC/cmM=emC/emM=betaM

afC/afM=cfC/cfM=efC/efM=betaF

but am not sure how I should proceed. Let's say I specify

NonlinearEfModel = mxModel (CholACEModel, name='NonlinearEf') bM = mxAlgebra(amC/amM, name='betaM') bM = mxAlgebra(cmC/cmM, name='betaM') bM = mxAlgebra(emC/emM, name='betaM') bF = mxAlgebra(afC/afM, name='betaF') bF = mxAlgebra(cfC/cfM, name='betaF') bF = mxAlgebra(efC/efM, name='betaF')

but how should I put all these new algebras into the model? Should I specify MZM, DZM, MZF and DZF models again?

And is it a right way to equate the algebras by giving them the same name? Would that work?

Thank you beforehand!

Julia