clpm: Cross lagged panel model

Description Usage Arguments Value

View source: R/clpm.h.R

Description

Cross lagged panel model

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
clpm(
  data,
  factors = list(list(label = "X", vars = list()), list(label = "Y", vars = list())),
  show_schematic_plot = TRUE,
  constrain_crosslagged = FALSE,
  constrain_autoregressions = FALSE,
  constrain_latent_variances = FALSE,
  constrain_observed_errors = FALSE,
  constrain_covariances = FALSE,
  estimate_observed_intercepts = TRUE,
  estimate_observed_errors = FALSE,
  estimate_latent_intercepts = FALSE,
  show_lavaan_syntax = FALSE,
  missing_data_treatment = "listwise"
)

Arguments

data

the data as a data frame

factors

a list containing named lists that define the label of the factor and the vars that belong to that factor

show_schematic_plot

.

constrain_crosslagged

.

constrain_autoregressions

.

constrain_latent_variances

.

constrain_observed_errors

.

constrain_covariances

.

estimate_observed_intercepts

.

estimate_observed_errors

.

estimate_latent_intercepts

.

show_lavaan_syntax

.

missing_data_treatment

.

Value

A results object containing:

results$lavaan_warnings a table
results$schematic_plot an image
results$text a preformatted
results$lavaan_syntax a preformatted

Tables can be converted to data frames with asDF or as.data.frame. For example:

results$lavaan_warnings$asDF

as.data.frame(results$lavaan_warnings)


Gootjes/longsem documentation built on Dec. 17, 2021, 10:22 p.m.