data_sem: Sample Dataset: A Latent Variable Mediation Model With 4...

data_semR Documentation

Sample Dataset: A Latent Variable Mediation Model With 4 Factors

Description

This data set is for testing functions in a four-factor structural model.

Usage

data_sem

Format

A data frame with 200 rows and 14 variables:

x01

Indicator. Numeric.

x02

Indicator. Numeric.

x03

Indicator. Numeric.

x04

Indicator. Numeric.

x05

Indicator. Numeric.

x06

Indicator. Numeric.

x07

Indicator. Numeric.

x08

Indicator. Numeric.

x09

Indicator. Numeric.

x10

Indicator. Numeric.

x11

Indicator. Numeric.

x12

Indicator. Numeric.

x13

Indicator. Numeric.

x14

Indicator. Numeric.

Examples

data(data_sem)
dat <- data_med_mod_b_mod
mod <-
  'f1 =~ x01 + x02 + x03
   f2 =~ x04 + x05 + x06 + x07
   f3 =~ x08 + x09 + x10
   f4 =~ x11 + x12 + x13 + x14
   f3 ~  a1*f1 + a2*f2
   f4 ~  b1*f1 + b3*f3
   a1b3 := a1 * b3
   a2b3 := a2 * b3
  '
fit <- lavaan::sem(model = mod, data = data_sem)
summary(fit)


manymome documentation built on Oct. 4, 2024, 5:10 p.m.