aMNLFA

aMNLFA package downloads to date

Page last updated: February 14, 2022

For the latest developments that may not yet be integrated into the aMNLFA package by CRAN, please visit https://github.com/vtcole/aMNLFA   


This page contains information about how to access and implement the aMNLFA (Automated Moderated Nonlinear Factor Analysis) R package described in Gottfredson et al. (2019).

The aMNLFA package and documentation are available through R’s CRAN repository. Here are instructions. A vignette and YouTube video are coming soon.

Please note that the aMNLFA package is provided as a convenient way to generate templates for pieces of code which should be edited, run, and interpreted manually in Mplus. While you can use this package to facilitate the process,  all model output must be inspected manually. There are a number of vital pieces of information which must be gleaned from actually looking at the output. For instance, the aMNLFA package does not read in warnings from Mplus about negative standard errors, untrustworthy parameter estimates, and the like. **The user must inspect their Mplus inputs and outputs themselves and alter them according to empirical judgment and substantive theory.** While we put this package into the scientific community with the aim of making it easier and more convenient for people to do high-quality measurement work, the reality is that the code it generates is not likely to be perfect. Each and every Mplus input file is meant to be checked, and potentially altered, by the user.


Please use the following citation to credit use of our package:

Cole, V.T., Gottfredson, N.C., Giordano, M., & Janssen, T. (2021). Automated fitting of moderated nonlinear factor analysis (MNLFA) through the Mplus program. R package version 1.0.


Subscribe to our e-mail listserve to receive package updates by e-mailing Nisha Gottfredson: gottfredson@unc.edu.


Version History:

February 13, 2022: aMNLFA version 1.1.2: Fixes a bug that resulted in incomplete declaration of loading DIF parameters in MODEL CONSTRAINTS.

——————————————————————————————-

July 1, 2021: Released aMNLFA version 1.0.0: Major bug fix, minor bug fix, added two features

**Major bug fixes.**

Most saliently, users pointed out that the simultaneous model (generated by aMNLFA.simultaneous()) was not correctly retaining effects from the itemwise measurement invariance models. Specifically, many loading effects and occasional intercept effects were being omitted from this model.

If you ran aMNLFA.simultaneous() without checking and altering the input before moving from aMNLFA.initial(), please rerun these functions using the new version. Also, please set thresholds = FALSE until the next version is released, while we work out a few issues with threshold DIF.

Some users were reporting issues with indexing when reading in input from the aMNLFA.simultaneous() function. We believe these have all been fixed in the current version, but please submit a bug report if you encounter an issue here.

**Minor bug fixes.**

The issue some users reported with generating plots of factor scores has been fixed.

**New features**

We have added two functions. First, we’ve improved functionality for testing threshold DIF. Before, there were a few functions that would misbehave when the user tried to examine DIF on the basis of thresholds. Second, we’ve added two functions– aMNLFA.prune() and aMNLFA.DIFplot()–and changed the implementation of aMNLFA.final(). The previous aMNLFA.final() function automated a lot of decisions away from the users. In particular, as you’ll note in Gottfredson et al. (2019), we generally advocate for a Benjamini-Hochberg correction to be applied when pruning DIF effects from the simultaneous model (i.e., the one fitted using aMNLFA.simultaneous()) to the final one. But this may not be the right decision for you. For instance, you may want to use an unadjusted p-value, or apply a more stringent adjustment, or define the number of tests differently from the way we’d defaulted to setting it up. The old version of the aMNLFA.final() function pretty much took those decisions away, so the two functions we’ve added will restore that functionality.

Click here for more details about the new functions.

Some functionality with testing threshold DIF still needs improvement. The threshold = TRUE option will be disabled in the coming version.

——————————————————————————————-

March 8, 2018: Released aMNLFA version 0.0.1