Attachment | Size |
---|---|

comparison_of_npsol_slsqp_lavaan.txt | 3.98 KB |

I ran a very simple one-factor with 3 indicators measurement error model. I used the default optimizer (SLSQP) and then the NPSOL optimizer that I've been using for a long time. Either NPSOL has been outputting bad intervals for a long time or SLSQP is not working very well for confidence intervals. Please see the attached text file that compares SLSQP, NPSOL, and lavaan results for the same model and same data. SLSQP does not compute some bounds, even though NPSOL has no problem computing bounds. (Note that the results include factor loadings, intercepts and variances. The OpenMx results have sds rather than variances while the lavaan results show the variances.)

I also needed to re-run a much more complex model using OpenMx 2.2.6 and using the default optimizer SLSQP. It ran much more quickly than under 1.3 with NPSOL - but many intervals were not computed and the bounds that were computed did not match very well (the estimates appeared to be very similar).

If you use summary(model, verbose=TRUE) then you can obtain additional diagnostics for the CIs. NPSOL

seemsto work better because we don't even bother to check whether NPSOL obtained the correct deviance target for the CI (if often does not).I'm sorry you're experiencing some trouble here. One of the things the OpenMx development team has been finding is that a feeling of certainty about ones results is often a consequence of limited options. That is, if you only have one optimizer then you think your optimizer works fine. Once you have options, idiosyncrasies can show.

One thing worth mentioning about the lavaan results is their confidence intervals are based purely on the standard errors. Many SEM programs do this. OpenMx does not. The confidence intervals provided by OpenMx are profile likelihood confidence intervals. They are not necessarily symmetric, and I believe they require less stringent assumptions than SE-based intervals. In theory they should be close to SE-based confidence intervals, but only when all the assumptions are met.

You can get SE-based confidence intervals for OpenMx models with something like

This could be put into a function.

Thanks!

I realize that lavaan is just using a simple approximation and that it can be difficult to compute profile intervals. I guess what concerns me most is that the 3-indicator one factor model is about as simple as it gets and the dataset is very well behaved (although without the constraint on the variances, the one variance would have a negative estimate). Given the likely undue weight put on p-values and even confidence intervals in published research, it seems there should be very prominent disclaimers about their accuracy. Most researchers are not going to take the time to investigate this especially when it would put them at a relative disadvantage.