Hello!,
I have prepared a script to compute a factor model (path diagram for Phillips and Fulker model ) of phenotypes of parents and twin children given by Neale.
I get an error message indicating the following sentence:
+ mxAlgebra( expression= (A%%(S%%t(C)))+(C%%(t(S)%%t(A))), name="J" ),
MZ Twin
- mxAlgebra( expression= (A%&%G%)+(C%&%R%)+J+(N%*%t(N)), name="U1" ),
Error: unexpected '&' in:
"mxAlgebra( expression= (A%%(S%%t(C)))+(C%%(t(S)%%t(A))), name="J" ),
mxAlgebra( expression= (A%&%G%)+(C%&"
> mxAlgebra( expression= H%x%(A%&%(G+H%x%(T%&%(t(D)+D)))+(C%&%R)+J+((H%x%H)%x%(N%%t(N))), name="V" ),# DZ Twin
Error: unexpected ',' in "mxAlgebra( expression= H%x%(A%&%(G+H%x%(T%&%(t(D)+D)))+(C%&%R)+J+((H%x%H)%x%(N%%t(N))),"
>
> # Algebra - Constraints
> #===========================================================
># Phenotypic Variance constraint
> mxAlgebra( expression= A&G+C&R+E%%t(E)+A%%S%%t(C)+C%%t(S)%%t(A)+N%%t(N), name="Z1" )
Error: unexpected ',' in "mxAlgebra( expression= A&G+C&R+E%%t(E)+A%%S%%t(C)+C%%t(S)%%t(A)+N%%t(N), name="Z1" ),"
> mxConstraint(as.mxMatrix(P)==as.mxMatrix(Z1)),
Error: unexpected ',' in "mxConstraint(as.mxMatrix(P)==as.mxMatrix(Z1)),"
========================================================= FIN
I think that the following operations are supported in mxAlgebra:
t( ), %*%, %x% and %&%.
Can the openMx team give me some advice ? Thank you in advance! :-)
Best Regards,
Maikol