umxCLPM: Runs cross-lagged panel models

View source: R/umxCLPM.R

umxCLPMR Documentation

Runs cross-lagged panel models

Description

One way of assessing causal relationships is by introducing time into the analyses. umxCLPM implements three cross-lagged panel models (CLPM) from the literature. The first is the classic CLPM from Heise (1969), the second is the CLPM from Hamaker et al. (2015), and the third is the CLPM from STARTS (1995). You simply pass the number of waves and the data set and the model you want to run.

Sketch mode is available, just do no pass data and you will be returned a model object to be manipulated later.

Usage

umxCLPM(
  waves,
  name = NULL,
  model = c("Hamaker2015", "Heise1969", "STARTS1995"),
  data = NULL,
  summary = !umx_set_silent(silent = TRUE),
  autoRun = getOption("umx_auto_run"),
  tryHard = c("no", "yes", "ordinal", "search")
)

Arguments

waves

Number of waves of data.

name

The name of the model (defaults to either "Heise1969", "Hamaker2015", or "STARTS1995").

model

Model type ("Hamaker2015", "Heise1969", or "STARTS1995")

data

Data frame for the analysis

summary

Optionally show a summary.

autoRun

Whether to run the model (default), or just to create it and return without running.

tryHard

Default ('no') uses normal mxRun. "yes" uses mxTryHard. Other options: "ordinal", "search"

Value

  • mxModel()

References

  • Kenny, D.A., & Zautra, A. (1995). The trait-state-error model for multiwave data. Journal of Consulting and Clinical Psychology, 63, 52–59. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1037/0022-006X.63.1.52")}

  • Hamaker E.L., Kuiper R.M., & Grasman R. (2015). A critique of the cross-lagged panel model. Psychological Methods, 20, 102–116. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1037/a0038889")}

  • Heise D. R. (1970). Causal inference from panel data. Sociological Methodology, 2, 3–27. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.2307/270780")}

Examples

## Not run: 

# ================
# = 1. Load Data =
# ================
data(docData)
dt <- docData[2:9]

# ============================
# = 2. Make a CLPM model     =
# ============================
hamaker <- umxCLPM(waves = 4, name = "mymodel", model = "Hamaker2015", data = dt)

## End(Not run)

umx documentation built on May 29, 2024, 5:40 a.m.

Related to umxCLPM in umx...