Abstract
In this article, we introduce and demonstrate the application of a newly developed R package RAMpath for tracing path diagrams and conducting structural longitudinal data analysis. RAMpath was developed to preserve the essential features of the classic DOS version of the RAMpath program (McArdle & Boker, 1990) and ease data analysis done through structural equation modeling (SEM). The applicability of RAMpath is demonstrated through a mediation model, a MIMIC model, several latent growth curve models, a univariate latent change score model, and a bivariate latent change score model. In addition to performing regular SEM analysis, RAMpath has unique features. First, it can generate path diagrams according to a given model. Second, it can display path tracing rules through path diagrams and decompose total effects into their respective direct and indirect effects as well as decompose variances and covariances into individual bridges. Furthermore, RAMpath can fit dynamic system models automatically based on latent change scores and generate vector field plots based on results obtained from a bivariate dynamic system. RAMpath is provided as an open-source R package.
Notes
1 The quotation marks in R should be straight instead of curly. If R has trouble recognizing the commands used in this article, first try to change the quotation marks.
2 Graphviz can be downloaded at http://www.graphviz.org/Download.php.
3 The URL to the data is http://dx.doi.org/10.3886/ICPSR04248.v3
4 Note that because of rounding error, the coefficients on the path diagram are slightly different from the text output. One can change the digits on the plot by adding the option digits= in the plot function.