You are here

OpenMx version 2.0 is officially released!

We are very pleased to announce that version 2.0 of OpenMx has been officially released! Users can download and install this new version by copy-pasting source('https://openmx.ssri.psu.edu/getOpenMx.R') into the R command line and pressing 'Return'. Users who still wish to download and install version 1.4, the previous stable version of the package, can instead use source('https://openmx.ssri.psu.edu/getOpenMx1.R').

A number of exciting new features are now available in OpenMx v2.0:

  • There is now a split between a model's expectation (how it's specified) and its fit function (its objective function to be minimized). In v1.4, expectation and fit were combined into one object, called an objective, for example by the R function mxRAMObjective(). The old "objective" syntax will still work, but the new split between expectation and fit enables greater flexibility in model-fitting by allowing users to mix-and-match different expectations with different fits.
  • LISREL specification of models is now possible, with mxExpectationLISREL().
  • There is now a simpler interface for setting up multigroup models, using mxFitFunctionMultigroup().
  • CSOLNP is a new, open-source numerical optimizer written in C++. For certain analyses, CSOLNP can be faster than NPSOL, and we are aware of several cases where it succeeds where NPSOL fails!
  • It is now possible to provide the optimizer with analytic derivatives of the fit function. NPSOL can accept analytic first derivatives (a gradient), and a new Newton-Raphson optimizer requires analytic first and second derivatives (a gradient and Hessian). These are provided by the user as mxAlgebras, and used with mxFitFunctionAlgebra().
  • mxCompute sequences, which can tell the program what to calculate and how to do so when running an MxModel.
  • New kinds of analyses are now possible in OpenMx, such as state-space modeling and Item Factor Analysis (IFA, a.k.a Item Response Theory).
  • A preliminary shiny app is available to generate source code for IFA models. See ifaTools (https://github.com/jpritikin/ifaTools).
  • To access slots of an MxModel object, @ accessors have been replaced with $ accessors. You no longer have to keep track of when to use which; just always use $! In fact, users should get into the habit of ALWAYS using the $ accessor instead of the @ accessor. For example, myModelRun@output$estimate would now be myModelRun$output$estimate. We CANNOT guarantee that every usage of the @ accessor that worked with versions 1.3/1.4 will continue to work in future versions.
  • Model output provided by summary() is now more concise (by default), and much of it has been made easier to read. Users who desire more extensive output can use argument verbose=TRUE--for example, summary(myModel, verbose=TRUE).
  • With RAM-specified models, summary() output no longer includes standardized path coefficients and their standard errors. This functionality is now handled by a new R function, mxStandardizeRAMpaths(). This new function provides a standardized path coefficient (and a standard error for it, if requested) for every nonzero path in the model, notwithstanding labels or whether it is a free parameter. If standard errors are requested, they are calculated by an improved method with a stronger statistical-theoretical justification than the rough approximation used in versions 1.3/1.4.
  • It is now possible to automatically run the saturated and independence models for certain kinds of model or dataset. This is useful for computing "absolute" fit indices (e.g., RMSEA, CFI, TLI) with summary().
  • A new R function, mxTryHard(), which makes multiple attempts to fit an MxModel object until the optimizer yields an acceptable solution or the maximum number of attempts is reached. Each attempt uses randomly jittered parameter estimates of the previous attempt as start values. From among its attempts, the function returns the fitted model with the smallest fit-function value, and prints to the console the start values it used for that model.
  • Several new functions are now usable in MxAlgebras: inverses of vech() and vechs(), cov2cor(), chol(), matrix logarithm and matrix exponential, lgamma(), and standard-normal quantile.

A number of bugs present in version 1.4 have now been fixed:

  • Version 1.4 had a serious bug pertaining to joint continuous-ordinal FIML analyses. If a column of ordinal data contained any missing values, the column was internally treated as continuous rather than ordinal.
  • In v1.4, it was not possible to re-run an already-run model that used mxRowObjective() due to a collision of matrix names. This is now possible (though note that mxFitFunctionRow() is now the preferred interface).
  • In v1.4, using summary() on a model using an R objective would sometimes fail with a mysterious error. Also, confidence limits computed for models using an R objective would be stored in the post-run model as being equal to the corresponding point estimate. Both of these bugs have now been repaired.
  • In earlier versions of mxEval() with defvar.row=n, mxEval() would return the computation based on row n of the internally sorted data, not row n of the data as supplied to mxData(). This feature was rarely used, so the bug existed for a long time. Please use OpenMx 2.0 to recompute any previously evaluated mxEval() calculations that use argument defvar.row.

There are a few known issues in version 2.0:

  • CSOLNP ignores certain Mx options--notably, the maximum number of iterations.
  • CSOLNP's memory management is still sub-optimal; the implication is that particularly difficult or lengthy optimization problems (especially confidence intervals) may cause memory leaks with potentially severe consequences, such as freezing up or crashing the system on which OpenMx is running.
  • Users who build OpenMx from source are cautioned that runnning the package with multithreading is not yet safe under Windows, and that doing so can crash R.
  • When taking a submatrix of an MxMatrix via square brackets, the resulting submatrix is always of type "Full," irrespective of the type of the original MxMatrix.
  • Users are advised that MxModels produced under OpenMx version 1.x and saved to an .RData file are not guaranteed to run under version 2.0 if reloaded from that .RData file.

Please post questions, comments, and issues to the OpenMx Forums!