# AE error message

6 posts / 0 new
Offline
Joined: 10/29/2010 - 09:21
AE error message

Hi,
I just upgraded to the newest version of OpenMx and R 2.15.0. I ran a simple univariate script and everything worked fine until the AE model. This is the error I get when I run the univAEFit:

> univAEFit <- mxRun(univAEModel, intervals=T)
Running univAE
Error: Unknown reference to 'AE.VarComp' detected in a confidence interval specification in model 'univAE' in runHelper(model, frontendStart, intervals, silent, suppressWarnings, unsafe, checkpoint, useSocket, onlyFrontend, useOptimizer).

However, setting intervals=F, the function runs properly and I can obtain statistics for the AE model.
I used the same script/data files on another PC - running the previous version of OpenMx and R 2.14.1 and the script runs without problems for all the three models. With the newer version, the BIC value for the Saturated, full ACE and the AE model is double the one I obtained with the previous version.

I think I have installed the required packages with all the dependencies... I am not sure what is going wrong...
Maria

Offline
Joined: 07/31/2009 - 15:12
Can you post your code so we

Can you post your code so we can look at your error more specifically? From what you've posted, it looks like VarComp isn't in your model.

Offline
Joined: 10/29/2010 - 09:21
AE error message

Dear Ryne,

thank you for answering so quickly. The script is attached.
I just wanted to point out that I get the estimates in the ACE full model.
Maria

Offline
Joined: 07/31/2009 - 15:12
There's no data, so I can't

There's no data, so I can't verify this, but I have a guess anyway. You don't have a model named 'AE' in your AE model tree, so the name 'AE.VarComp' doesn't refer to anything. Your submodel in the AE model is still named 'ACE'.

Offline
Joined: 07/31/2009 - 15:24
I think I see the culprit.

I think I see the culprit. The inner model is not being renamed from 'ACE' to 'AE'. I would use the mxRename() command, twice, since you are renaming the parent model and then a child model. You have a number of algebras that refer to 'ACE.something' and the mxRename() will adjust the algebras. The following correction should work:

univAEModel <- mxRename(univACEFit, "univAE")
univAEModel <- mxRename(univAEModel, "AE", "ACE")
univAEModel$AE.c <- mxMatrix( type="Lower", nrow=1, ncol=1, free=FALSE, values=0, label="c11", name="c" ) univAEModel$AE.VarComp <- mxAlgebra( expression=cbind(A/V, C/V, E/V), name="VarComp")
univAEModel <- mxModel(univAEModel, mxCI (c('AE.VarComp')))   # drop c at 0

And now I am going off on a tangent: there are a number of example OpenMx scripts floating out in the world that adopt this pattern of 1 parent model that contains three child models named "ACE", "MZ", and "DZ". I would recommend switching to one of the following alternatives: (a) rename the child model "ACE" to "common". From that point onwards, rename the parent model to a new name (using mxRename) whenever you want to make changes. Or (b) Place all of the entities that reside in the "ACE" model into the parent model, and eliminate the "ACE" model. I prefer these two approaches as each of them requires only a single call to mxRename() when I wish to change the model.

Offline
Joined: 10/29/2010 - 09:21
Great, Thank you! the script

Great, Thank you!

the script worked - will amend my other scripts.
Now I get estimates, CI and AIC as before. The BIC is still double the value I was obtaining using the previous version of OpenMx - in all three models, is this a problem?

Maria