You are here

Not positive definite error when all within-studies covariance matrices are positive definite

3 posts / 0 new
Last post
forscher's picture
Offline
Joined: 03/05/2013 - 09:31
Not positive definite error when all within-studies covariance matrices are positive definite

Hi Mike (and the rest of the forum),

Thanks so much for maintaining your metaSEM package!

I have been trying to fit a variation of a network meta-analysis model using your package. In particular, I need to impose specific constraints on the estimated between-studies covariance matrix. However, my question is not about the constraints that I'm imposing, but rather about a not positive definite error that I haven't been able to figure out.

If you read in the attached data and use the check_pd() function to test whether the within-studies covariance matrices are positive definite, you will see that they all are. However, when I attempt to run my model using meta(), I get the following error:

"The job for model 'Meta analysis with ML' exited abnormally with the error message: MxComputeGradientDescent: fitfunction Meta analysis with ML.fitfunction is not finite (Expected covariance matrix for continuous variables is not positive-definite in data row 32)"

What's odd is that I've fit a similar model using the mvmeta package (without the constraints on the between-studies covariance matrix that I want -- this isn't possible in mvmeta) without any errors. So, I'm forced to conclude that either I've mis-specified my model using meta() or that something strange is occurring within meta() or mxRun().

Do you have any suggestions for what might be happening?

Mike Cheung's picture
Offline
Joined: 10/08/2009 - 22:37
Hi Patrick, I don't have a

Hi Patrick,

I don't have a concret answer. However, there are only a few cases on each effect size, e.g., 5 cases for threat_1 and threat_2, and 6 cases for inc_goal_1 and inc_goal_2 (see the attached output). There may not have enough data to calculate the covariances of the random effects.

I have tried a model with only diagonals on the random effects (mod1b in the attached file). It seems fine though I don't know whether it makes in your context.

Cheers,
Mike

forscher's picture
Offline
Joined: 03/05/2013 - 09:31
Thanks, Mike. I was able to

Thanks, Mike. I was able to remove the error by modifying the start values, so it appears that the model is identifiable in metaSEM.