Fit Structural Equation Models using Generalized Structural Component Analysis

Share:

Description

Fit a generalized structured component analysis (GSCA) model. gesca 1.0 can handle various extensions of GSCA, including imposing constraints on parameters, second-order latent variable modeling, multiple-group analysis, the calculation of total and indirect effects, and missing value imputation.

Usage

1
2
3
gesca.run(myModel, data, group.name = NULL, group.equal = NULL,
          nbt = 100, itmax = 100, ceps = 1e-5,
          moption = 0, missingvalue = -9999)

Arguments

myModel

A simple description of the user-specified model using the gesca model syntax. The model can be described by strings or multiple lines of formulas. See Details and Examples below.

data

A data matrix or frame including the observed variables used in myModel.

group.name

A character string only used in a multiple group analysis. A variable name in the data frame which defines the group membership of each case. The user can specify which variable is used to provide group memberships for a multiple group analysis. If NULL (the default), a single-group GSCA will be run.

group.equal

A vector of character strings only used in a multiple group analysis. It can be one or both of the following: "loadings" or "paths", specifying the pattern of equality constraints across multiple groups. The default is set to NULL (the default), assuming that all parameters are freely estimated in each group. See Details and Examples below.

nbt

Denote the number of bootstrap samples. In gesca 1.0, the bootstrap method is employed to obtain the standard errors of parameter estimates. By default, nbt is set to 100, but any non-negative numeric value can be used. If the number of bootstrap samples is equal to 0, only the values of parameter estimates obtained from the original dataset will be reported without their standard errors and CIs.

itmax

The maximum number of iterations for the alternating least-squares (ALS) algorithm. The default value is set to 100.

ceps

Convergence threshold for the ALS algorithm. The default is set to 0.00001.

moption

Options of handling missing data. By default, it is assumed that no value is missing in all variables. gesca 1.0 currently offers three options for handling missing data and the choice should be one of the following: list-wise deletion (moption = 1), mean substitution (moption = 2), and least-squares imputation (moption = 3).

missingvalue

A missing value identifier. Only used if moption is specified. By default, every element of -9999 in data is defined as a missing value. Users can use any numeric or integer value to specify missing values in data. See Examples below.

Details

General Overview of the gesca Model Syntax:

In gesca 1.0, the user can write one or more formula lines to specify a structural equation model. This is the gesca model syntax for the gesca.run function. The model syntax consists of character strings or multiple lines of formulas as follows:

1) To specify the relationships between indicators and latent variables, the user can use the =~ operator. For example, the model syntax Y =~ X1 + X2 + X3 means the latent variable Y is related to the indicators X1, X2, and X3.

2) The relationships among latent variables can be expressed with the ~ operator. For example, the syntax Y1 ~ Y2 + Y3 shows that Y1 is regressed on Y2 and Y3.

3) The user can consider a second-order latent variable that is linked to a set of first-order latent variables. This can be described by the =: operator. For example, the syntax H1 =: Y1+Y2+Y3 indicates that a second-order latent variable, H1, is related to its lower-order latent variables Y1, Y2, and Y3.

Importantly, the variable names in the gesca model syntax should correspond to the variable names in the data frame. If the option group.name is used for a multiple-group GSCA, the same model structure is fitted across groups by default.

Constraining Parameters in the gesca Model Syntax:

If the user wants to fix or constrain parameters to constants, it can be done in the gesca model syntax by adding values or labels followed by the * operator. For example, in the following model syntax, the path coefficients of L1 regressed on L4 and of L4 regressed on L5 are fixed at 0.01 and 0.6, respectively:

myModel <- "

L1 =~ z1 + z2 + z3

L2 =~ z4 + z5 + z6

L3 =~ z7 + z8

L4 =~ z9 + z10 + z11

L5 =~ z12

L2 ~ L1

L3 ~ L1 + L2

L4 ~ 0.01*L1 + L2 + L3

L5 ~ 0.6*L4

"

The above model is identical to the following model using labels (instead of values):

myModel <- "

L1 =~ z1 + z2 + z3

L2 =~ z4 + z5 + z6

L3 =~ z7 + z8

L4 =~ z9 + z10 + z11

L5 =~ z12

L2 ~ L1

L3 ~ L1 + L2

L4 ~ c1*L1 + L2 + L3

L5 ~ c2*L4

c1 == 0.01

c2 == 0.6

"

Constraining Parameters in a Multiple-Group GSCA:

Any across-group equality constraints can be imposed on parameters in the same way as above. In addition, the group.equal option can be used to constrain all loadings and/or all path coefficients across groups simultaneously. To demonstrate the imposition of across-group equality constraints on all loadings and path coefficients, the user can simply input group.equal = c("loadings", "paths"), then the gesca.run function estimates a single set of loadings and path coefficients that is fixed to be equal across groups. Similarly, group.equal = c("loadings") treats all loadings to be fixed across all groups, and group.equal = c("paths") returns identical path estimates in each group. See Examples for more details.

Reflective/Formative Indicators in the gesca Model Syntax:

In gesca 1.0, the relationships between indicators and latent variables can be either reflective or formative and this can be defined by the operator (1) or (0), respectively. The user can input these operators in the model syntax lines that contain the =~ and/or the =: operators. If (1) or (0) argument is omitted, by default, the gesca.run function will treat all the relationships defined by =~ and/or =: as reflective. For example, the model syntax Y =~ X1 + X2 or Y(1) =~ X1 + X2 means that X1 and X2 are reflective. Similarly, when the second-order latent variable has effects on its first-order latent variables, the relationship can be defined as H1 =: Y1+Y2 or H1(1) =: Y1+Y2. On the other hand, if the first-order latent variables are considered formative, the model syntax is expressed as Y(0) =~ X1 + X2, which involves no loadings for X1 and X2.

Missing Value Imputation:

To use the missing value identifier of the gesca.run function, missing values in the data frame should be represented by numeric codes (e.g. -9999, 99, -9) and specified by the missingvalue option. This can be used only when the moption argument is used. If the data have missing value codes but the user omits the missingvalue argument, the gesca.run function will treat the missing values as regular data values (except for the value of -9999 by default).

Value

An object of class gesca.run, for which a summary method and four functions in gesca 1.0 (effectmeasures, fitmeasures, latentmeasures, and qualmeasures) are available.

References

Hwang, H., & Takane, Y. (2014). Generalized structured component analysis: A Component-Based Approach to Structural Equation Modeling (pp.13-126). Boca Raton, FL: Chapman & Hall/CRC Press.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
library(gesca)
data(gesca.rick2) # Organizational identification example of Bagozzi
                  # has the grouping variable "gender"

# Model specification
myModel <- "
		# Measurement model 
		OP =~ cei1 + cei2 + cei3
		OI =~ ma1 + ma2 + ma3
		AC_J =~ orgcmt1 + orgcmt2 + orgcmt3
		AC_L =~ orgcmt5 + orgcmt6 + orgcmt8
		
		# Structural model 
		OI ~ OP
		AC_J ~ OI
		AC_L ~ OI
"

# In case the user wants to apply a single-group analysis ignoring the group information:
# rick2.GSCA <- gesca.run(myModel, gesca.rick2)

# Run a multiple-group GSCA with the grouping variable gender:
# GSCA.group <- gesca.run(myModel, gesca.rick2, group.name = "gender")
# summary(GSCA.group)
GSCA.group.nbt0 <- gesca.run(myModel, gesca.rick2, group.name ="gender", nbt = 0)
summary(GSCA.group.nbt0)		# no bootstrapped std errors
effectmeasures(GSCA.group.nbt0)

# Models with the imposition of constraints on parameters across groups
# (1) equality constraints
# equl.cstr <- gesca.run(myModel, gesca.rick2, group.name ="gender",
#                  group.equal = c("loadings", "paths"))

# (2) identical loadings but different path coefficients
# equl.loadings <- gesca.run(myModel, gesca.rick2, group.name ="gender",
#                      group.equal = c("loadings"))

# (3) More constraints across groups with some formative indicators
myModel.con <- "
		OP =~ cei1 + cei2 + cei3
		OI(0) =~ ma1 + ma2 + ma3
		AC_J =~ c(g,g)*orgcmt1 + c(h,h)*orgcmt2 + c(i,i)*orgcmt3
		AC_L(0) =~ orgcmt5 + orgcmt6 + orgcmt8

		OI ~ 0.37*OP
		AC_J ~ OI
		AC_L ~ OI
"
Const.Form <- gesca.run(myModel.con, gesca.rick2, group.name ="gender", nbt = 50)
summary(Const.Form)


# Second-order latent variable modeling
myModel5 <- "
		# Measurement model 
		OP =~ cei1 + cei2 + cei3 + cei4 + cei5 + cei6 + cei7 + cei8
		OI =~ ma1 + ma2 + ma3 + ma4 + ma5 + ma6
		AC_J =~ orgcmt1 + orgcmt2 + orgcmt3 + orgcmt7
		AC_L =~ orgcmt5 + orgcmt6 + orgcmt8

		# Second-order latents 
		AC =: AC_J + AC_L

		# Structural model 
		OI ~ OP
		AC ~ OI
"

# second.GSCA <- gesca.run(myModel5, gesca.rick2, group.name = "gender")
# summary(second.GSCA)
second.GSCA.nbt0 <- gesca.run(myModel5, gesca.rick2, group.name = "gender", nbt=0)
summary(second.GSCA.nbt0)