Skip to contents
library(modsem)
#> This is modsem (1.0.20). Please report any bugs!

Composite Constructs

As of version 1.0.20, the modsem function supports the estimation of models with composite constructs, when using method="lms". The approach is based on Tamara Schamberger, Florian Schuberth, Jörg Henseler & Yves Rosseel, 2015. Depending on your lavaan version (>=0.6-20), composite constructs can also be used with the product indicator approaches (e.g., method="dblcent").

Here we can see a simple example, using the LMS approach with the TPB dataset.

tpb <- '
# Outer Model (Based on Hagger et al., 2007)
  # Latent Variables
  SN =~ sn1 + sn2
  PBC =~ pbc1 + pbc2 + pbc3
  INT =~ int1 + int2 + int3

  # Composites
  ATT <~ att1 + att2 + att3 + att4 + att5
  BEH <~ b1 + b2

# Inner Model (Based on Steinmetz et al., 2011)
  INT ~ ATT + SN + PBC
  BEH ~ INT + PBC + INT:PBC
'

fit <- modsem(tpb, TPB, method = "lms", nodes = 32)
summary(fit)
#> 
#> modsem (1.0.20) ended normally after 38 iterations
#> 
#>   Estimator                                        LMS
#>   Optimization method                       EMA-NLMINB
#>   Number of model parameters                        47
#> 
#>   Number of observations                          2000
#> 
#> Loglikelihood and Information Criteria:
#>   Loglikelihood                              -26324.50
#>   Akaike (AIC)                                52743.00
#>   Bayesian (BIC)                              53006.24
#>  
#> Numerical Integration:
#>   Points of integration (per dim)                   32
#>   Dimensions                                         1
#>   Total points of integration                       32
#> 
#> Fit Measures for Baseline Model (H0):
#>                                               Standard
#>   Chi-square                                     63.05
#>   Degrees of Freedom (Chi-square)                   71
#>   P-value (Chi-square)                           0.738
#>   RMSEA                                          0.000
#>                                                       
#>   Loglikelihood                              -26391.61
#>   Akaike (AIC)                                52875.22
#>   Bayesian (BIC)                              53132.86
#>  
#> Comparative Fit to H0 (LRT test):
#>   Loglikelihood change                           67.11
#>   Difference test (D)                           134.22
#>   Degrees of freedom (D)                             1
#>   P-value (D)                                    0.000
#>  
#> R-Squared Interaction Model (H1):
#>   INT                                            0.364
#>   BEH                                            0.232
#> R-Squared Baseline Model (H0):
#>   INT                                            0.364
#>   BEH                                            0.186
#> R-Squared Change (H1 - H0):
#>   INT                                            0.000
#>   BEH                                            0.045
#> 
#> Parameter Estimates:
#>   Coefficients                          unstandardized
#>   Information                                 observed
#>   Standard errors                             standard
#>  
#> Latent Variables:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>   SN =~         
#>     sn1             1.000                             
#>     sn2             0.888      0.017   52.608    0.000
#>   PBC =~        
#>     pbc1            1.000                             
#>     pbc2            0.912      0.013   69.336    0.000
#>     pbc3            0.801      0.012   65.994    0.000
#>   INT =~        
#>     int1            1.000                             
#>     int2            0.913      0.015   59.047    0.000
#>     int3            0.807      0.014   55.729    0.000
#> 
#> Composites:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>   ATT <~        
#>     att1            1.000                             
#>     att2            0.675      0.260    2.598    0.009
#>     att3            0.866      0.278    3.122    0.002
#>     att4            0.836      0.271    3.081    0.002
#>     att5            1.118      0.311    3.594    0.000
#>   BEH <~        
#>     b1              1.000                             
#>     b2              1.484      0.395    3.757    0.000
#> 
#> Regressions:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>   INT ~         
#>     SN              0.182      0.027    6.612    0.000
#>     PBC             0.226      0.029    7.766    0.000
#>     ATT             0.051      0.011    4.725    0.000
#>   BEH ~         
#>     PBC             0.563      0.102    5.536    0.000
#>     INT             0.461      0.096    4.815    0.000
#>     INT:PBC         0.496      0.088    5.661    0.000
#> 
#> Intercepts:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>    .pbc1            0.997      0.024   42.388    0.000
#>    .pbc2            0.984      0.022   44.908    0.000
#>    .pbc3            0.991      0.020   50.428    0.000
#>    .sn1             1.005      0.024   41.633    0.000
#>    .sn2             1.010      0.022   46.682    0.000
#>     att1            1.013      0.024   41.979    0.000
#>     att2            1.006      0.021   46.939    0.000
#>     att3            1.016      0.020   51.427    0.000
#>     att4            0.999      0.018   55.625    0.000
#>     att5            0.992      0.022   45.644    0.000
#>    .int1            1.013      0.022   46.939    0.000
#>    .int2            1.012      0.020   50.380    0.000
#>    .int3            1.005      0.018   54.780    0.000
#>     b1              1.002      0.021   47.006    0.000
#>     b2              1.019      0.020   51.016    0.000
#> 
#> Covariances:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>   att2 ~~       
#>     att1            0.878                             
#>   att3 ~~       
#>     att1            0.788                             
#>     att2            0.692                             
#>   att4 ~~       
#>     att1            0.693                             
#>     att2            0.609                             
#>     att3            0.547                             
#>   att5 ~~       
#>     att1            0.885                             
#>     att2            0.778                             
#>     att3            0.698                             
#>     att4            0.616                             
#>   b2 ~~         
#>     b1              0.605                             
#>   SN ~~         
#>     ATT             2.428      0.435    5.575    0.000
#>   PBC ~~        
#>     SN              0.678      0.029   23.326    0.000
#>     ATT             2.614      0.467    5.592    0.000
#> 
#> Variances:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>    .pbc1            0.144      0.008   18.384    0.000
#>    .pbc2            0.160      0.007   21.434    0.000
#>    .pbc3            0.155      0.006   23.881    0.000
#>    .sn1             0.178      0.015   12.076    0.000
#>    .sn2             0.157      0.012   13.270    0.000
#>     att1            1.166                             
#>     att2            0.920                             
#>     att3            0.781                             
#>     att4            0.645                             
#>     att5            0.944                             
#>    .int1            0.157      0.009   18.097    0.000
#>    .int2            0.160      0.008   20.408    0.000
#>    .int3            0.168      0.007   23.553    0.000
#>     b1              0.815                             
#>     b2              0.716                             
#>     SN              0.988      0.039   25.403    0.000
#>     PBC             0.963      0.035   27.226    0.000
#>     ATT            15.450      5.390    2.866    0.004
#>    .INT             0.493      0.020   24.709    0.000
#>    .BEH             3.166      1.004    3.153    0.002