if (!require(lavaan)) install.packages("lavaan")
Loading required package: lavaan
This is lavaan 0.5-23.1097
lavaan is BETA software! Please report any bugs.
library(lavaan)

Longitudinal Invariance CFA (using MLR) Example in lavaan (N = 151; 6 items over 3 occasions)

These data measuring a latent trait of social functioning were collected at a Psychiatric Rehabilitation center, in which time 1 was admittance, and times 2 and 3 were collected at six-month intervals. There were six subscales that were completed by the hospital staff for each patient, including positively-oriented measures of Social Competence, Social Interest, and Personal Neatness, and negatively-oriented measures of Psychoticism, Motor Retardation, and Irritability. The negatively-oriented subscales were reflected (*−1) prior to analysis. Initial models examined the fit of one-factor versus two-factor models given the two valences of the subscales, but the fit of the two-factor model was not a significant improvement, and thus a one-factor model with all six items was used here.

#read in data
cafData = read.table(file = "CAF.dat", header = FALSE, na.strings = "9999")
names(cafData) = c("ID", "v1T1", "v1T2", "v1T3", "v2T1", "v2T2", "v2T3", "v3T1", "v3T2", "v3T3", "v4T1", "v4T2", "v4T3", "v5T1", "v5T2", "v5T3", "v6T1", "v6T2", "v6T3")
#recode negatively worded items
cafData$v4T1 = cafData$v4T1*(-1); cafData$v4T2 = cafData$v4T2*(-1); cafData$v4T3 = cafData$v4T3*(-1);
cafData$v5T1 = cafData$v5T1*(-1); cafData$v5T2 = cafData$v5T2*(-1); cafData$v5T3 = cafData$v5T3*(-1);
cafData$v6T1 = cafData$v6T1*(-1); cafData$v6T2 = cafData$v6T2*(-1); cafData$v6T3 = cafData$v6T3*(-1);

1. Configural Longitudinal Invariance Model (everything separate across time)

Note: as groups are not defined in our data, we will not be using the the multiple group syntax in lavaan. Instead, we will build our code where the three factors are the three groups.

configuralSyntax = "
#===================================================================================================
#Factor loadings all freely estimated in each group with labels
Time1 =~ L1T1*v1T1 + L2T1*v2T1 + L3T1*v3T1 + L4T1*v4T1 + L5T1*v5T1 + L6T1*v6T1
Time2 =~ L1T2*v1T2 + L2T2*v2T2 + L3T2*v3T2 + L4T2*v4T2 + L5T2*v5T2 + L6T2*v6T2
Time3 =~ L1T3*v1T3 + L2T3*v2T3 + L3T3*v3T3 + L4T3*v4T3 + L5T3*v5T3 + L6T3*v6T3
#===================================================================================================
#Item intercepts all freely estimated in each group with labels
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3T1*1; v4T1 ~ I4T1*1; v5T1 ~ I5T1*1; v6T1 ~ I6T1*1; 
v1T2 ~ I1T2*1; v2T2 ~ I2T2*1;  v3T2 ~ I3T2*1; v4T2 ~ I4T2*1; v5T2 ~ I5T2*1; v6T2 ~ I6T2*1; 
v1T3 ~ I1T3*1; v2T3 ~ I2T3*1;  v3T3 ~ I3T3*1; v4T3 ~ I4T3*1; v5T3 ~ I5T3*1; v6T3 ~ I6T3*1; 
#===================================================================================================
#Redidual variances all freely estimated in each group with labels
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3T1*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5T1*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1T2*v1T2; v2T2 ~~ E2T2*v2T2;  v3T2 ~~ E3T2*v3T2; v4T2 ~~ E4T2*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6T2*v6T2;
v1T3 ~~ E1T3*v1T3; v2T3 ~~ E2T3*v2T3;  v3T3 ~~ E3T3*v3T3; v4T3 ~~ E4T3*v4T3; v5T3 ~~ E5T3*v5T3; v6T3 ~~ E6T3*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in each group
Time1 ~~ 1*Time1
Time2 ~~ 1*Time2
Time3 ~~ 1*Time3
#===================================================================================================
#Factor mean fixed to zero for identification in each group
Time1 ~ 0
Time2 ~ 0
Time3 ~ 0
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
#===================================================================================================
"
configuralEstimates = lavaan(model = configuralSyntax, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(configuralEstimates, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 118 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              292.514     283.247
  Degrees of freedom                               114         114
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.033
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.912       0.903
  Tucker-Lewis Index (TLI)                       0.883       0.870

  Robust Comparative Fit Index (CFI)                         0.913
  Robust Tucker-Lewis Index (TLI)                            0.884

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4430.302   -4430.302
  Scaling correction factor                                  1.462
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         75          75
  Akaike (AIC)                                9010.604    9010.604
  Bayesian (BIC)                              9236.900    9236.900
  Sample-size adjusted Bayesian (BIC)         8999.533    8999.533

Root Mean Square Error of Approximation:

  RMSEA                                          0.102       0.099
  90 Percent Confidence Interval          0.088  0.116       0.085  0.113
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.101
  90 Percent Confidence Interval                             0.086  0.116

Standardized Root Mean Square Residual:

  SRMR                                           0.089       0.089

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.222    0.267   12.063    0.000    3.222    0.989
    v2T1    (L2T1)    1.915    0.274    6.997    0.000    1.915    0.545
    v3T1    (L3T1)    2.080    0.209    9.956    0.000    2.080    0.801
    v4T1    (L4T1)    1.975    0.271    7.298    0.000    1.975    0.593
    v5T1    (L5T1)    0.931    0.148    6.281    0.000    0.931    0.568
    v6T1    (L6T1)    1.441    0.119   12.101    0.000    1.441    0.742
  Time2 =~                                                              
    v1T2    (L1T2)    2.863    0.305    9.372    0.000    2.863    0.970
    v2T2    (L2T2)    2.072    0.197   10.490    0.000    2.072    0.649
    v3T2    (L3T2)    2.133    0.185   11.509    0.000    2.133    0.821
    v4T2    (L4T2)    2.098    0.322    6.514    0.000    2.098    0.628
    v5T2    (L5T2)    1.175    0.239    4.921    0.000    1.175    0.477
    v6T2    (L6T2)    1.512    0.129   11.749    0.000    1.512    0.821
  Time3 =~                                                              
    v1T3    (L1T3)    2.550    0.288    8.865    0.000    2.550    0.962
    v2T3    (L2T3)    1.961    0.230    8.539    0.000    1.961    0.654
    v3T3    (L3T3)    1.751    0.210    8.323    0.000    1.751    0.750
    v4T3    (L4T3)    1.678    0.260    6.448    0.000    1.678    0.551
    v5T3    (L5T3)    1.021    0.170    6.012    0.000    1.021    0.511
    v6T3    (L6T3)    1.523    0.159    9.574    0.000    1.523    0.869

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.214    0.250   -0.855    0.393   -0.214   -0.609
   .v1T3   (C1T13)   -0.004    0.247   -0.016    0.987   -0.004   -0.011
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.113    0.231    0.488    0.626    0.113    0.218
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.949    0.682    5.787    0.000    3.949    0.552
   .v2T3   (C2T13)    2.256    0.805    2.803    0.005    2.256    0.338
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.154    0.580    3.718    0.000    2.154    0.391
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.965    0.289    3.340    0.001    0.965    0.419
   .v3T3   (C3T13)    1.172    0.284    4.135    0.000    1.172    0.489
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.241    0.316    3.931    0.000    1.241    0.542
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.853    0.863    5.623    0.000    4.853    0.695
   .v4T3   (C4T13)    3.801    1.033    3.679    0.000    3.801    0.557
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.588    0.821    5.592    0.000    4.588    0.694
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.349    0.767    3.064    0.002    2.349    0.804
   .v5T3   (C5T13)    1.429    0.441    3.243    0.001    1.429    0.617
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    2.887    0.777    3.717    0.000    2.887    0.778
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.824    0.162    5.096    0.000    0.824    0.603
   .v6T3   (C6T13)    0.592    0.182    3.251    0.001    0.592    0.525
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.547    0.140    3.910    0.000    0.547    0.601
  Time1 ~~                                                              
    Time2             0.786    0.042   18.827    0.000    0.786    0.786
    Time3             0.707    0.084    8.456    0.000    0.707    0.707
  Time2 ~~                                                              
    Time3             0.671    0.089    7.532    0.000    0.671    0.671

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.077    0.276   58.220    0.000   16.077    4.933
   .v2T1    (I2T1)    8.672    0.298   29.132    0.000    8.672    2.469
   .v3T1    (I3T1)   11.970    0.225   53.108    0.000   11.970    4.611
   .v4T1    (I4T1)   -3.037    0.271  -11.216    0.000   -3.037   -0.912
   .v5T1    (I5T1)   -1.283    0.138   -9.293    0.000   -1.283   -0.782
   .v6T1    (I6T1)   -2.871    0.164  -17.508    0.000   -2.871   -1.478
   .v1T2    (I1T2)   17.226    0.245   70.294    0.000   17.226    5.837
   .v2T2    (I2T2)    9.981    0.263   37.921    0.000    9.981    3.124
   .v3T2    (I3T2)   12.467    0.218   57.265    0.000   12.467    4.799
   .v4T2    (I4T2)   -3.211    0.260  -12.349    0.000   -3.211   -0.961
   .v5T2    (I5T2)   -1.664    0.200   -8.338    0.000   -1.664   -0.676
   .v6T2    (I6T2)   -2.413    0.158  -15.316    0.000   -2.413   -1.311
   .v1T3    (I1T3)   17.756    0.220   80.621    0.000   17.756    6.699
   .v2T3    (I2T3)   10.442    0.281   37.204    0.000   10.442    3.483
   .v3T3    (I3T3)   13.029    0.213   61.157    0.000   13.029    5.583
   .v4T3    (I4T3)   -2.738    0.249  -11.014    0.000   -2.738   -0.899
   .v5T3    (I5T3)   -1.247    0.166   -7.511    0.000   -1.247   -0.625
   .v6T3    (I6T3)   -2.075    0.152  -13.618    0.000   -2.075   -1.184
    Time1             0.000                               0.000    0.000
    Time2             0.000                               0.000    0.000
    Time3             0.000                               0.000    0.000

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.241    0.395    0.610    0.542    0.241    0.023
   .v2T1    (E2T1)    8.672    1.022    8.484    0.000    8.672    0.703
   .v3T1    (E3T1)    2.413    0.398    6.067    0.000    2.413    0.358
   .v4T1    (E4T1)    7.199    1.036    6.950    0.000    7.199    0.649
   .v5T1    (E5T1)    1.824    0.446    4.093    0.000    1.824    0.678
   .v6T1    (E6T1)    1.694    0.243    6.974    0.000    1.694    0.449
   .v1T2    (E1T2)    0.511    0.268    1.907    0.056    0.511    0.059
   .v2T2    (E2T2)    5.913    0.617    9.581    0.000    5.913    0.579
   .v3T2    (E3T2)    2.202    0.369    5.972    0.000    2.202    0.326
   .v4T2    (E4T2)    6.765    0.990    6.834    0.000    6.765    0.606
   .v5T2    (E5T2)    4.676    1.439    3.251    0.001    4.676    0.772
   .v6T2    (E6T2)    1.103    0.166    6.643    0.000    1.103    0.326
   .v1T3    (E1T3)    0.523    0.349    1.497    0.134    0.523    0.074
   .v2T3    (E2T3)    5.142    0.806    6.379    0.000    5.142    0.572
   .v3T3    (E3T3)    2.381    0.430    5.542    0.000    2.381    0.437
   .v4T3    (E4T3)    6.456    1.078    5.988    0.000    6.456    0.696
   .v5T3    (E5T3)    2.944    0.752    3.913    0.000    2.944    0.739
   .v6T3    (E6T3)    0.751    0.162    4.630    0.000    0.751    0.244
    Time1             1.000                               1.000    1.000
    Time2             1.000                               1.000    1.000
    Time3             1.000                               1.000    1.000

R-Square:
                   Estimate
    v1T1              0.977
    v2T1              0.297
    v3T1              0.642
    v4T1              0.351
    v5T1              0.322
    v6T1              0.551
    v1T2              0.941
    v2T2              0.421
    v3T2              0.674
    v4T2              0.394
    v5T2              0.228
    v6T2              0.674
    v1T3              0.926
    v2T3              0.428
    v3T3              0.563
    v4T3              0.304
    v5T3              0.261
    v6T3              0.756

Although the fit is not great, attempts to improve it logically were unsuccessful, so we proceed from here with this as the configural invariance model. This foreshadows the metric invariance section up next.

2. Metric Invariance Models (ALL loadings held equal across time - identified model using Time1 Factor Variance = 1)

metricSyntax1 = "
#===================================================================================================
#Factor loadings all constrained across groups with labels *****
Time1 =~ L1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2 + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3 + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all freely estimated in each group with labels
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3T1*1; v4T1 ~ I4T1*1; v5T1 ~ I5T1*1; v6T1 ~ I6T1*1; 
v1T2 ~ I1T2*1; v2T2 ~ I2T2*1;  v3T2 ~ I3T2*1; v4T2 ~ I4T2*1; v5T2 ~ I5T2*1; v6T2 ~ I6T2*1; 
v1T3 ~ I1T3*1; v2T3 ~ I2T3*1;  v3T3 ~ I3T3*1; v4T3 ~ I4T3*1; v5T3 ~ I5T3*1; v6T3 ~ I6T3*1; 
#===================================================================================================
#Redidual variances all freely estimated in each group with labels
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3T1*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5T1*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1T2*v1T2; v2T2 ~~ E2T2*v2T2;  v3T2 ~~ E3T2*v3T2; v4T2 ~~ E4T2*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6T2*v6T2;
v1T3 ~~ E1T3*v1T3; v2T3 ~~ E2T3*v2T3;  v3T3 ~~ E3T3*v3T3; v4T3 ~~ E4T3*v4T3; v5T3 ~~ E5T3*v5T3; v6T3 ~~ E6T3*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3;  
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others *****
Time1 ~~ 1*Time1
Time2 ~~ Time2
Time3 ~~ Time3
#===================================================================================================
#Factor mean fixed to zero for identification in each group
Time1 ~ 0
Time2 ~ 0
Time3 ~ 0
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
#===================================================================================================
"
metricEstimates1 = lavaan(model = metricSyntax1, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(metricEstimates1, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 120 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              316.712     301.234
  Degrees of freedom                               124         124
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.051
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.905       0.898
  Tucker-Lewis Index (TLI)                       0.883       0.875

  Robust Comparative Fit Index (CFI)                         0.908
  Robust Tucker-Lewis Index (TLI)                            0.886

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4442.401   -4442.401
  Scaling correction factor                                  1.260
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         65          65
  Akaike (AIC)                                9014.803    9014.803
  Bayesian (BIC)                              9210.926    9210.926
  Sample-size adjusted Bayesian (BIC)         9005.208    9005.208

Root Mean Square Error of Approximation:

  RMSEA                                          0.101       0.097
  90 Percent Confidence Interval          0.088  0.115       0.084  0.111
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.100
  90 Percent Confidence Interval                             0.085  0.114

Standardized Root Mean Square Residual:

  SRMR                                           0.094       0.094

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1      (L1)    3.004    0.249   12.073    0.000    3.004    0.962
    v2T1      (L2)    2.117    0.204   10.365    0.000    2.117    0.588
    v3T1      (L3)    2.139    0.200   10.699    0.000    2.139    0.822
    v4T1      (L4)    2.018    0.256    7.873    0.000    2.018    0.599
    v5T1      (L5)    0.981    0.147    6.659    0.000    0.981    0.588
    v6T1      (L6)    1.611    0.125   12.865    0.000    1.611    0.783
  Time2 =~                                                              
    v1T2      (L1)    3.004    0.249   12.073    0.000    2.938    0.975
    v2T2      (L2)    2.117    0.204   10.365    0.000    2.070    0.647
    v3T2      (L3)    2.139    0.200   10.699    0.000    2.091    0.814
    v4T2      (L4)    2.018    0.256    7.873    0.000    1.973    0.605
    v5T2      (L5)    0.981    0.147    6.659    0.000    0.959    0.405
    v6T2      (L6)    1.611    0.125   12.865    0.000    1.575    0.834
  Time3 =~                                                              
    v1T3      (L1)    3.004    0.249   12.073    0.000    2.621    0.969
    v2T3      (L2)    2.117    0.204   10.365    0.000    1.847    0.630
    v3T3      (L3)    2.139    0.200   10.699    0.000    1.866    0.772
    v4T3      (L4)    2.018    0.256    7.873    0.000    1.760    0.568
    v5T3      (L5)    0.981    0.147    6.659    0.000    0.856    0.446
    v6T3      (L6)    1.611    0.125   12.865    0.000    1.406    0.844

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.208    0.255   -0.815    0.415   -0.208   -0.361
   .v1T3   (C1T13)    0.035    0.235    0.150    0.880    0.035    0.062
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.096    0.230    0.417    0.677    0.096    0.212
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.930    0.678    5.796    0.000    3.930    0.552
   .v2T3   (C2T13)    2.107    0.792    2.659    0.008    2.107    0.318
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.131    0.583    3.655    0.000    2.131    0.383
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.953    0.281    3.388    0.001    0.953    0.431
   .v3T3   (C3T13)    1.090    0.279    3.911    0.000    1.090    0.479
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.222    0.325    3.763    0.000    1.222    0.532
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.821    0.874    5.515    0.000    4.821    0.688
   .v4T3   (C4T13)    3.895    1.031    3.778    0.000    3.895    0.565
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.590    0.810    5.668    0.000    4.590    0.692
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.325    0.762    3.052    0.002    2.325    0.796
   .v5T3   (C5T13)    1.403    0.435    3.223    0.001    1.403    0.605
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    2.863    0.783    3.656    0.000    2.863    0.768
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.809    0.158    5.133    0.000    0.809    0.609
   .v6T3   (C6T13)    0.559    0.176    3.172    0.002    0.559    0.490
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.531    0.133    3.981    0.000    0.531    0.573
  Time1 ~~                                                              
    Time2             0.769    0.072   10.625    0.000    0.787    0.787
    Time3             0.626    0.115    5.431    0.000    0.717    0.717
  Time2 ~~                                                              
    Time3             0.573    0.116    4.935    0.000    0.671    0.671

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.086    0.274   58.644    0.000   16.086    5.150
   .v2T1    (I2T1)    8.662    0.299   28.948    0.000    8.662    2.406
   .v3T1    (I3T1)   11.965    0.226   52.891    0.000   11.965    4.600
   .v4T1    (I4T1)   -3.042    0.269  -11.325    0.000   -3.042   -0.903
   .v5T1    (I5T1)   -1.292    0.138   -9.363    0.000   -1.292   -0.775
   .v6T1    (I6T1)   -2.877    0.164  -17.490    0.000   -2.877   -1.399
   .v1T2    (I1T2)   17.230    0.245   70.337    0.000   17.230    5.716
   .v2T2    (I2T2)    9.983    0.264   37.869    0.000    9.983    3.119
   .v3T2    (I3T2)   12.472    0.217   57.359    0.000   12.472    4.851
   .v4T2    (I4T2)   -3.207    0.259  -12.367    0.000   -3.207   -0.983
   .v5T2    (I5T2)   -1.664    0.200   -8.334    0.000   -1.664   -0.702
   .v6T2    (I6T2)   -2.412    0.158  -15.294    0.000   -2.412   -1.278
   .v1T3    (I1T3)   17.768    0.221   80.464    0.000   17.768    6.567
   .v2T3    (I2T3)   10.431    0.280   37.301    0.000   10.431    3.557
   .v3T3    (I3T3)   13.041    0.212   61.633    0.000   13.041    5.395
   .v4T3    (I4T3)   -2.723    0.254  -10.709    0.000   -2.723   -0.878
   .v5T3    (I5T3)   -1.246    0.169   -7.382    0.000   -1.246   -0.649
   .v6T3    (I6T3)   -2.086    0.153  -13.615    0.000   -2.086   -1.253
    Time1             0.000                               0.000    0.000
    Time2             0.000                               0.000    0.000
    Time3             0.000                               0.000    0.000

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.729    0.353    2.064    0.039    0.729    0.075
   .v2T1    (E2T1)    8.485    1.026    8.270    0.000    8.485    0.654
   .v3T1    (E3T1)    2.190    0.334    6.552    0.000    2.190    0.324
   .v4T1    (E4T1)    7.281    1.045    6.968    0.000    7.281    0.641
   .v5T1    (E5T1)    1.819    0.444    4.096    0.000    1.819    0.654
   .v6T1    (E6T1)    1.635    0.237    6.906    0.000    1.635    0.386
   .v1T2    (E1T2)    0.455    0.263    1.730    0.084    0.455    0.050
   .v2T2    (E2T2)    5.963    0.612    9.738    0.000    5.963    0.582
   .v3T2    (E3T2)    2.235    0.361    6.191    0.000    2.235    0.338
   .v4T2    (E4T2)    6.745    0.964    6.996    0.000    6.745    0.634
   .v5T2    (E5T2)    4.694    1.429    3.286    0.001    4.694    0.836
   .v6T2    (E6T2)    1.082    0.162    6.674    0.000    1.082    0.304
   .v1T3    (E1T3)    0.452    0.325    1.391    0.164    0.452    0.062
   .v2T3    (E2T3)    5.187    0.793    6.538    0.000    5.187    0.603
   .v3T3    (E3T3)    2.361    0.427    5.527    0.000    2.361    0.404
   .v4T3    (E4T3)    6.522    1.101    5.925    0.000    6.522    0.678
   .v5T3    (E5T3)    2.958    0.772    3.834    0.000    2.958    0.802
   .v6T3    (E6T3)    0.796    0.169    4.699    0.000    0.796    0.287
    Time1             1.000                               1.000    1.000
    Time2             0.956    0.153    6.233    0.000    1.000    1.000
    Time3             0.761    0.134    5.663    0.000    1.000    1.000

R-Square:
                   Estimate
    v1T1              0.925
    v2T1              0.346
    v3T1              0.676
    v4T1              0.359
    v5T1              0.346
    v6T1              0.614
    v1T2              0.950
    v2T2              0.418
    v3T2              0.662
    v4T2              0.366
    v5T2              0.164
    v6T2              0.696
    v1T3              0.938
    v2T3              0.397
    v3T3              0.596
    v4T3              0.322
    v5T3              0.198
    v6T3              0.713

Does the metric model (metricEstimates1) fit worse than the configural model (configuralEstimates)? Yes, −2∆LL(df=10) = 19.14, p =.04.

anova(metricEstimates1, configuralEstimates)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                     Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)  
configuralEstimates 114 9010.6 9236.9 292.51                                
metricEstimates1    124 9014.8 9210.9 316.71     19.142      10     0.0385 *
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

To investigate which parameter to free, we will look at the modification indices:

#get modification indices for all parameters:
metricMI1 = modificationindices(metricEstimates1, free.remove = FALSE, maximum.number = 10000)
#restrict output to only factor loading parameters
metricMI1a = metricMI1[which(metricMI1$op == "=~"),]
#restrict output to only factors and items with same time point
metricMI1a$factorTime = metricMI1a$lhs
#extract time characters from items
metricMI1a$itemTime = substr(metricMI1a$rhs, 3, 4)
#convert to same name as factors
metricMI1a$itemTime[which(metricMI1a$itemTime == "T1")] = "Time1"
metricMI1a$itemTime[which(metricMI1a$itemTime == "T2")] = "Time2"
metricMI1a$itemTime[which(metricMI1a$itemTime == "T3")] = "Time3"
#show only MIs for same time
metricMI1b = metricMI1a[which(metricMI1a$itemTime == metricMI1a$factorTime),]
metricMI1b[order(-metricMI1b$mi),]
     lhs op  rhs    mi mi.scaled    epc sepc.lv sepc.all sepc.nox factorTime itemTime
18 Time3 =~ v6T3 5.684     5.406  0.210   0.183    0.110    0.110      Time3    Time3
1  Time1 =~ v1T1 5.678     5.400  0.271   0.271    0.087    0.087      Time1    Time1
11 Time2 =~ v5T2 3.302     3.140  0.186   0.182    0.077    0.077      Time2    Time2
5  Time1 =~ v5T1 3.297     3.136 -0.138  -0.138   -0.083   -0.083      Time1    Time1
6  Time1 =~ v6T1 2.694     2.562 -0.156  -0.156   -0.076   -0.076      Time1    Time1
13 Time3 =~ v1T3 1.817     1.729 -0.155  -0.135   -0.050   -0.050      Time3    Time3
10 Time2 =~ v4T2 0.946     0.899  0.150   0.147    0.045    0.045      Time2    Time2
15 Time3 =~ v3T3 0.924     0.879 -0.142  -0.124   -0.051   -0.051      Time3    Time3
7  Time2 =~ v1T2 0.826     0.786 -0.089  -0.087   -0.029   -0.029      Time2    Time2
17 Time3 =~ v5T3 0.633     0.602  0.102   0.089    0.046    0.046      Time3    Time3
2  Time1 =~ v2T1 0.553     0.526 -0.163  -0.163   -0.045   -0.045      Time1    Time1
12 Time2 =~ v6T2 0.542     0.515 -0.055  -0.054   -0.028   -0.028      Time2    Time2
9  Time2 =~ v3T2 0.423     0.402  0.076   0.074    0.029    0.029      Time2    Time2
16 Time3 =~ v4T3 0.410     0.390 -0.136  -0.119   -0.038   -0.038      Time3    Time3
14 Time3 =~ v2T3 0.396     0.377  0.151   0.132    0.045    0.045      Time3    Time3
4  Time1 =~ v4T1 0.339     0.323 -0.104  -0.104   -0.031   -0.031      Time1    Time1
8  Time2 =~ v2T2 0.020     0.019  0.025   0.025    0.008    0.008      Time2    Time2
3  Time1 =~ v3T1 0.013     0.012  0.014   0.014    0.005    0.005      Time1    Time1

From these MIs there are two that are large-ish, the loading of item1 at time1 and the loading of item3 at time3, which have almost the same values. For consistency with the Mplus example, we will select the loading of item1 at time1 to free and continue. In practice, we would free one of these two parameters, not necessarily the one we have chosen.

metricSyntax2 = "
#===================================================================================================
#Factor loadings constrained across groups except non-invariant ones *****
Time1 =~ L1T1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2   + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3   + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all freely estimated in each group with labels
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3T1*1; v4T1 ~ I4T1*1; v5T1 ~ I5T1*1; v6T1 ~ I6T1*1; 
v1T2 ~ I1T2*1; v2T2 ~ I2T2*1;  v3T2 ~ I3T2*1; v4T2 ~ I4T2*1; v5T2 ~ I5T2*1; v6T2 ~ I6T2*1; 
v1T3 ~ I1T3*1; v2T3 ~ I2T3*1;  v3T3 ~ I3T3*1; v4T3 ~ I4T3*1; v5T3 ~ I5T3*1; v6T3 ~ I6T3*1; 
#===================================================================================================
#Redidual variances all freely estimated in each group with labels
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3T1*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5T1*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1T2*v1T2; v2T2 ~~ E2T2*v2T2;  v3T2 ~~ E3T2*v3T2; v4T2 ~~ E4T2*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6T2*v6T2;
v1T3 ~~ E1T3*v1T3; v2T3 ~~ E2T3*v2T3;  v3T3 ~~ E3T3*v3T3; v4T3 ~~ E4T3*v4T3; v5T3 ~~ E5T3*v5T3; v6T3 ~~ E6T3*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others *****
Time1 ~~ 1*Time1
Time2 ~~ Time2
Time3 ~~ Time3
#===================================================================================================
#Factor mean fixed to zero for identification in each group
Time1 ~ 0
Time2 ~ 0
Time3 ~ 0
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
#===================================================================================================
"
metricEstimates2 = lavaan(model = metricSyntax2, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(metricEstimates2, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 116 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              303.247     290.300
  Degrees of freedom                               123         123
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.045
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.912       0.904
  Tucker-Lewis Index (TLI)                       0.890       0.881

  Robust Comparative Fit Index (CFI)                         0.913
  Robust Tucker-Lewis Index (TLI)                            0.892

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4435.669   -4435.669
  Scaling correction factor                                  1.284
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         66          66
  Akaike (AIC)                                9003.337    9003.337
  Bayesian (BIC)                              9202.478    9202.478
  Sample-size adjusted Bayesian (BIC)         8993.595    8993.595

Root Mean Square Error of Approximation:

  RMSEA                                          0.099       0.095
  90 Percent Confidence Interval          0.085  0.113       0.081  0.109
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.097
  90 Percent Confidence Interval                             0.083  0.111

Standardized Root Mean Square Residual:

  SRMR                                           0.091       0.091

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.233    0.261   12.362    0.000    3.233    0.992
    v2T1      (L2)    1.950    0.201    9.707    0.000    1.950    0.551
    v3T1      (L3)    1.967    0.198    9.910    0.000    1.967    0.779
    v4T1      (L4)    1.899    0.224    8.481    0.000    1.899    0.578
    v5T1      (L5)    0.968    0.137    7.055    0.000    0.968    0.582
    v6T1      (L6)    1.476    0.131   11.247    0.000    1.476    0.749
  Time2 =~                                                              
    v1T2      (L1)    2.644    0.234   11.315    0.000    2.849    0.968
    v2T2      (L2)    1.950    0.201    9.707    0.000    2.102    0.655
    v3T2      (L3)    1.967    0.198    9.910    0.000    2.120    0.821
    v4T2      (L4)    1.899    0.224    8.481    0.000    2.047    0.619
    v5T2      (L5)    0.968    0.137    7.055    0.000    1.043    0.434
    v6T2      (L6)    1.476    0.131   11.247    0.000    1.591    0.836
  Time3 =~                                                              
    v1T3      (L1)    2.644    0.234   11.315    0.000    2.564    0.963
    v2T3      (L2)    1.950    0.201    9.707    0.000    1.892    0.639
    v3T3      (L3)    1.967    0.198    9.910    0.000    1.908    0.782
    v4T3      (L4)    1.899    0.224    8.481    0.000    1.842    0.582
    v5T3      (L5)    0.968    0.137    7.055    0.000    0.939    0.480
    v6T3      (L6)    1.476    0.131   11.247    0.000    1.432    0.850

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.225    0.249   -0.904    0.366   -0.225   -0.737
   .v1T3   (C1T13)   -0.012    0.236   -0.049    0.961   -0.012   -0.039
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.132    0.230    0.574    0.566    0.132    0.250
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.963    0.679    5.834    0.000    3.963    0.553
   .v2T3   (C2T13)    2.251    0.806    2.791    0.005    2.251    0.335
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.142    0.580    3.691    0.000    2.142    0.388
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    1.008    0.296    3.411    0.001    1.008    0.432
   .v3T3   (C3T13)    1.148    0.285    4.023    0.000    1.148    0.478
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.175    0.316    3.717    0.000    1.175    0.524
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.811    0.848    5.672    0.000    4.811    0.691
   .v4T3   (C4T13)    3.890    1.027    3.787    0.000    3.890    0.565
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.685    0.827    5.667    0.000    4.685    0.701
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.347    0.762    3.079    0.002    2.347    0.802
   .v5T3   (C5T13)    1.423    0.438    3.248    0.001    1.423    0.613
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    2.868    0.779    3.684    0.000    2.868    0.773
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.833    0.164    5.090    0.000    0.833    0.610
   .v6T3   (C6T13)    0.592    0.177    3.350    0.001    0.592    0.511
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.533    0.135    3.951    0.000    0.533    0.576
  Time1 ~~                                                              
    Time2             0.847    0.078   10.837    0.000    0.786    0.786
    Time3             0.682    0.124    5.508    0.000    0.703    0.703
  Time2 ~~                                                              
    Time3             0.699    0.128    5.473    0.000    0.669    0.669

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.078    0.276   58.267    0.000   16.078    4.934
   .v2T1    (I2T1)    8.672    0.298   29.071    0.000    8.672    2.452
   .v3T1    (I3T1)   11.978    0.225   53.192    0.000   11.978    4.745
   .v4T1    (I4T1)   -3.034    0.267  -11.343    0.000   -3.034   -0.924
   .v5T1    (I5T1)   -1.288    0.137   -9.377    0.000   -1.288   -0.775
   .v6T1    (I6T1)   -2.871    0.164  -17.506    0.000   -2.871   -1.457
   .v1T2    (I1T2)   17.225    0.245   70.282    0.000   17.225    5.851
   .v2T2    (I2T2)    9.980    0.264   37.872    0.000    9.980    3.108
   .v3T2    (I3T2)   12.468    0.217   57.325    0.000   12.468    4.826
   .v4T2    (I4T2)   -3.210    0.260  -12.365    0.000   -3.210   -0.970
   .v5T2    (I5T2)   -1.663    0.199   -8.340    0.000   -1.663   -0.692
   .v6T2    (I6T2)   -2.414    0.158  -15.319    0.000   -2.414   -1.269
   .v1T3    (I1T3)   17.756    0.222   80.036    0.000   17.756    6.671
   .v2T3    (I2T3)   10.434    0.280   37.245    0.000   10.434    3.526
   .v3T3    (I3T3)   13.041    0.212   61.441    0.000   13.041    5.347
   .v4T3    (I4T3)   -2.720    0.254  -10.720    0.000   -2.720   -0.860
   .v5T3    (I5T3)   -1.246    0.169   -7.373    0.000   -1.246   -0.637
   .v6T3    (I6T3)   -2.087    0.154  -13.571    0.000   -2.087   -1.240
    Time1             0.000                               0.000    0.000
    Time2             0.000                               0.000    0.000
    Time3             0.000                               0.000    0.000

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.170    0.374    0.454    0.650    0.170    0.016
   .v2T1    (E2T1)    8.702    1.026    8.483    0.000    8.702    0.696
   .v3T1    (E3T1)    2.502    0.386    6.484    0.000    2.502    0.393
   .v4T1    (E4T1)    7.172    1.021    7.021    0.000    7.172    0.665
   .v5T1    (E5T1)    1.829    0.443    4.131    0.000    1.829    0.661
   .v6T1    (E6T1)    1.707    0.242    7.059    0.000    1.707    0.439
   .v1T2    (E1T2)    0.548    0.265    2.070    0.038    0.548    0.063
   .v2T2    (E2T2)    5.895    0.605    9.746    0.000    5.895    0.572
   .v3T2    (E3T2)    2.178    0.352    6.183    0.000    2.178    0.326
   .v4T2    (E4T2)    6.759    0.967    6.990    0.000    6.759    0.617
   .v5T2    (E5T2)    4.678    1.430    3.272    0.001    4.678    0.811
   .v6T2    (E6T2)    1.090    0.165    6.599    0.000    1.090    0.301
   .v1T3    (E1T3)    0.509    0.314    1.618    0.106    0.509    0.072
   .v2T3    (E2T3)    5.177    0.795    6.514    0.000    5.177    0.591
   .v3T3    (E3T3)    2.309    0.416    5.548    0.000    2.309    0.388
   .v4T3    (E4T3)    6.613    1.129    5.860    0.000    6.613    0.661
   .v5T3    (E5T3)    2.944    0.760    3.872    0.000    2.944    0.770
   .v6T3    (E6T3)    0.784    0.170    4.618    0.000    0.784    0.277
    Time1             1.000                               1.000    1.000
    Time2             1.162    0.185    6.270    0.000    1.000    1.000
    Time3             0.941    0.157    5.999    0.000    1.000    1.000

R-Square:
                   Estimate
    v1T1              0.984
    v2T1              0.304
    v3T1              0.607
    v4T1              0.335
    v5T1              0.339
    v6T1              0.561
    v1T2              0.937
    v2T2              0.428
    v3T2              0.674
    v4T2              0.383
    v5T2              0.189
    v6T2              0.699
    v1T3              0.928
    v2T3              0.409
    v3T3              0.612
    v4T3              0.339
    v5T3              0.230
    v6T3              0.723
anova(metricEstimates2, configuralEstimates)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                     Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)
configuralEstimates 114 9010.6 9236.9 292.51                              
metricEstimates2    123 9003.3 9202.5 303.25      8.981       9      0.439

The likelihood ratio test suggests that the partial metric invariance model fits as well as the configural model.

#get modification indices for all parameters:
metricMI2 = modificationindices(metricEstimates2, free.remove = FALSE, maximum.number = 10000)
#restrict output to only factor loading parameters
metricMI2a = metricMI2[which(metricMI2$op == "=~"),]
#restrict output to only factors and items with same time point
metricMI2a$factorTime = metricMI2a$lhs
#extract time characters from items
metricMI2a$itemTime = substr(metricMI2a$rhs, 3, 4)
#convert to same name as factors
metricMI2a$itemTime[which(metricMI2a$itemTime == "T1")] = "Time1"
metricMI2a$itemTime[which(metricMI2a$itemTime == "T2")] = "Time2"
metricMI2a$itemTime[which(metricMI2a$itemTime == "T3")] = "Time3"
#show only MIs for same time
metricMI2b = metricMI2a[which(metricMI2a$itemTime == metricMI2a$factorTime),]
metricMI2b[order(-metricMI2b$mi),]
     lhs op  rhs    mi mi.scaled    epc sepc.lv sepc.all sepc.nox factorTime itemTime
18 Time3 =~ v6T3 3.279     3.139  0.143   0.138    0.082    0.082      Time3    Time3
15 Time3 =~ v3T3 2.363     2.262 -0.204  -0.197   -0.081   -0.081      Time3    Time3
12 Time2 =~ v6T2 2.020     1.934 -0.097  -0.105   -0.055   -0.055      Time2    Time2
11 Time2 =~ v5T2 1.506     1.442  0.112   0.121    0.050    0.050      Time2    Time2
5  Time1 =~ v5T1 1.393     1.333 -0.086  -0.086   -0.052   -0.052      Time1    Time1
16 Time3 =~ v4T3 1.030     0.986 -0.194  -0.188   -0.059   -0.059      Time3    Time3
3  Time1 =~ v3T1 1.024     0.980  0.124   0.124    0.049    0.049      Time1    Time1
10 Time2 =~ v4T2 0.192     0.184  0.061   0.066    0.020    0.020      Time2    Time2
4  Time1 =~ v4T1 0.139     0.133  0.064   0.064    0.020    0.020      Time1    Time1
14 Time3 =~ v2T3 0.127     0.122  0.077   0.075    0.025    0.025      Time3    Time3
9  Time2 =~ v3T2 0.125     0.120  0.037   0.040    0.016    0.016      Time2    Time2
17 Time3 =~ v5T3 0.100     0.095  0.036   0.035    0.018    0.018      Time3    Time3
13 Time3 =~ v1T3 0.072     0.069 -0.028  -0.027   -0.010   -0.010      Time3    Time3
7  Time2 =~ v1T2 0.054     0.052  0.021   0.022    0.008    0.008      Time2    Time2
6  Time1 =~ v6T1 0.041     0.040 -0.019  -0.019   -0.010   -0.010      Time1    Time1
2  Time1 =~ v2T1 0.025     0.024 -0.034  -0.034   -0.010   -0.010      Time1    Time1
8  Time2 =~ v2T2 0.022     0.021 -0.024  -0.026   -0.008   -0.008      Time2    Time2
1  Time1 =~ v1T1 0.000     0.000  0.000   0.000    0.000    0.000      Time1    Time1

The modification indices indicate no other changes are needed, so we can continue.

3. Scalar Invariance Models (ALL loadings held equal across time - identified model using Time1 Factor Mean = 1)

scalarSyntax1 = "
#===================================================================================================
#Factor loadings constrained across groups except non-invariant ones
Time1 =~ L1T1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2 + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3 + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all constrained across groups except non-invariant ones ****
v1T1 ~ I1T1*1; v2T1 ~ I2*1;  v3T1 ~ I3*1; v4T1 ~ I4*1; v5T1 ~ I5*1; v6T1 ~ I6*1; 
v1T2 ~ I1*1;   v2T2 ~ I2*1;  v3T2 ~ I3*1; v4T2 ~ I4*1; v5T2 ~ I5*1; v6T2 ~ I6*1; 
v1T3 ~ I1*1;   v2T3 ~ I2*1;  v3T3 ~ I3*1; v4T3 ~ I4*1; v5T3 ~ I5*1; v6T3 ~ I6*1; 
#===================================================================================================
#Redidual variances all freely estimated in each group with labels
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3T1*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5T1*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1T2*v1T2; v2T2 ~~ E2T2*v2T2;  v3T2 ~~ E3T2*v3T2; v4T2 ~~ E4T2*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6T2*v6T2;
v1T3 ~~ E1T3*v1T3; v2T3 ~~ E2T3*v2T3;  v3T3 ~~ E3T3*v3T3; v4T3 ~~ E4T3*v4T3; v5T3 ~~ E5T3*v5T3; v6T3 ~~ E6T3*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others
Time1 ~~ 1*Time1
Time2 ~~ Time2
Time3 ~~ Time3
#===================================================================================================
#Factor mean fixed to zero for identification first group, estimated in others ****
Time1 ~ 0
Time2 ~ 1
Time3 ~ 1
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
"
scalarEstimates1 = lavaan(model = scalarSyntax1, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(scalarEstimates1, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 116 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              355.594     342.529
  Degrees of freedom                               132         132
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.038
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.890       0.879
  Tucker-Lewis Index (TLI)                       0.873       0.860

  Robust Comparative Fit Index (CFI)                         0.892
  Robust Tucker-Lewis Index (TLI)                            0.874

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4461.842   -4461.842
  Scaling correction factor                                  1.143
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         57          57
  Akaike (AIC)                                9037.685    9037.685
  Bayesian (BIC)                              9209.670    9209.670
  Sample-size adjusted Bayesian (BIC)         9029.271    9029.271

Root Mean Square Error of Approximation:

  RMSEA                                          0.106       0.103
  90 Percent Confidence Interval          0.093  0.119       0.090  0.116
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.105
  90 Percent Confidence Interval                             0.091  0.118

Standardized Root Mean Square Residual:

  SRMR                                           0.093       0.093

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.223    0.264   12.216    0.000    3.223    0.988
    v2T1      (L2)    2.072    0.198   10.454    0.000    2.072    0.563
    v3T1      (L3)    2.023    0.193   10.496    0.000    2.023    0.791
    v4T1      (L4)    1.794    0.234    7.660    0.000    1.794    0.553
    v5T1      (L5)    0.907    0.152    5.962    0.000    0.907    0.555
    v6T1      (L6)    1.516    0.127   11.977    0.000    1.516    0.759
  Time2 =~                                                              
    v1T2      (L1)    2.662    0.230   11.597    0.000    2.834    0.964
    v2T2      (L2)    2.072    0.198   10.454    0.000    2.206    0.673
    v3T2      (L3)    2.023    0.193   10.496    0.000    2.153    0.827
    v4T2      (L4)    1.794    0.234    7.660    0.000    1.910    0.593
    v5T2      (L5)    0.907    0.152    5.962    0.000    0.966    0.390
    v6T2      (L6)    1.516    0.127   11.977    0.000    1.613    0.841
  Time3 =~                                                              
    v1T3      (L1)    2.662    0.230   11.597    0.000    2.557    0.960
    v2T3      (L2)    2.072    0.198   10.454    0.000    1.991    0.663
    v3T3      (L3)    2.023    0.193   10.496    0.000    1.943    0.789
    v4T3      (L4)    1.794    0.234    7.660    0.000    1.724    0.560
    v5T3      (L5)    0.907    0.152    5.962    0.000    0.872    0.438
    v6T3      (L6)    1.516    0.127   11.977    0.000    1.456    0.858

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.187    0.251   -0.746    0.456   -0.187   -0.484
   .v1T3   (C1T13)    0.026    0.240    0.107    0.914    0.026    0.069
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.140    0.230    0.610    0.542    0.140    0.242
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.926    0.712    5.517    0.000    3.926    0.532
   .v2T3   (C2T13)    2.047    0.812    2.519    0.012    2.047    0.299
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.079    0.560    3.715    0.000    2.079    0.381
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.985    0.291    3.378    0.001    0.985    0.430
   .v3T3   (C3T13)    1.090    0.289    3.770    0.000    1.090    0.462
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.166    0.317    3.675    0.000    1.166    0.527
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.606    0.837    5.501    0.000    4.606    0.658
   .v4T3   (C4T13)    3.681    1.016    3.624    0.000    3.681    0.534
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.515    0.796    5.674    0.000    4.515    0.683
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.430    0.835    2.910    0.004    2.430    0.785
   .v5T3   (C5T13)    1.487    0.489    3.041    0.002    1.487    0.613
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    3.203    0.935    3.425    0.001    3.203    0.786
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.823    0.166    4.959    0.000    0.823    0.611
   .v6T3   (C6T13)    0.571    0.177    3.231    0.001    0.571    0.505
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.519    0.134    3.884    0.000    0.519    0.576
  Time1 ~~                                                              
    Time2             0.837    0.077   10.811    0.000    0.787    0.787
    Time3             0.678    0.121    5.588    0.000    0.706    0.706
  Time2 ~~                                                              
    Time3             0.689    0.124    5.553    0.000    0.674    0.674

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.089    0.274   58.671    0.000   16.089    4.933
   .v2T1      (I2)    9.368    0.263   35.672    0.000    9.368    2.545
   .v3T1      (I3)   12.026    0.227   53.055    0.000   12.026    4.704
   .v4T1      (I4)   -3.388    0.261  -12.988    0.000   -3.388   -1.045
   .v5T1      (I5)   -1.189    0.125   -9.520    0.000   -1.189   -0.728
   .v6T1      (I6)   -2.775    0.169  -16.456    0.000   -2.775   -1.390
   .v1T2      (I1)   16.589    0.281   59.112    0.000   16.589    5.646
   .v2T2      (I2)    9.368    0.263   35.672    0.000    9.368    2.859
   .v3T2      (I3)   12.026    0.227   53.055    0.000   12.026    4.618
   .v4T2      (I4)   -3.388    0.261  -12.988    0.000   -3.388   -1.052
   .v5T2      (I5)   -1.189    0.125   -9.520    0.000   -1.189   -0.480
   .v6T2      (I6)   -2.775    0.169  -16.456    0.000   -2.775   -1.447
   .v1T3      (I1)   16.589    0.281   59.112    0.000   16.589    6.226
   .v2T3      (I2)    9.368    0.263   35.672    0.000    9.368    3.119
   .v3T3      (I3)   12.026    0.227   53.055    0.000   12.026    4.885
   .v4T3      (I4)   -3.388    0.261  -12.988    0.000   -3.388   -1.100
   .v5T3      (I5)   -1.189    0.125   -9.520    0.000   -1.189   -0.598
   .v6T3      (I6)   -2.775    0.169  -16.456    0.000   -2.775   -1.636
    Time1             0.000                               0.000    0.000
    Time2             0.228    0.081    2.831    0.005    0.214    0.214
    Time3             0.452    0.083    5.456    0.000    0.471    0.471

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.247    0.390    0.635    0.526    0.247    0.023
   .v2T1    (E2T1)    9.256    1.165    7.947    0.000    9.256    0.683
   .v3T1    (E3T1)    2.443    0.391    6.243    0.000    2.443    0.374
   .v4T1    (E4T1)    7.291    1.014    7.189    0.000    7.291    0.694
   .v5T1    (E5T1)    1.846    0.458    4.027    0.000    1.846    0.692
   .v6T1    (E6T1)    1.692    0.247    6.849    0.000    1.692    0.424
   .v1T2    (E1T2)    0.603    0.269    2.247    0.025    0.603    0.070
   .v2T2    (E2T2)    5.874    0.599    9.812    0.000    5.874    0.547
   .v3T2    (E3T2)    2.145    0.351    6.115    0.000    2.145    0.316
   .v4T2    (E4T2)    6.714    0.962    6.978    0.000    6.714    0.648
   .v5T2    (E5T2)    5.196    1.648    3.153    0.002    5.196    0.848
   .v6T2    (E6T2)    1.073    0.164    6.560    0.000    1.073    0.292
   .v1T3    (E1T3)    0.560    0.312    1.794    0.073    0.560    0.079
   .v2T3    (E2T3)    5.060    0.769    6.577    0.000    5.060    0.561
   .v3T3    (E3T3)    2.284    0.416    5.494    0.000    2.284    0.377
   .v4T3    (E4T3)    6.512    1.117    5.832    0.000    6.512    0.687
   .v5T3    (E5T3)    3.193    0.882    3.620    0.000    3.193    0.808
   .v6T3    (E6T3)    0.757    0.169    4.484    0.000    0.757    0.263
    Time1             1.000                               1.000    1.000
    Time2             1.133    0.179    6.315    0.000    1.000    1.000
    Time3             0.923    0.152    6.082    0.000    1.000    1.000

R-Square:
                   Estimate
    v1T1              0.977
    v2T1              0.317
    v3T1              0.626
    v4T1              0.306
    v5T1              0.308
    v6T1              0.576
    v1T2              0.930
    v2T2              0.453
    v3T2              0.684
    v4T2              0.352
    v5T2              0.152
    v6T2              0.708
    v1T3              0.921
    v2T3              0.439
    v3T3              0.623
    v4T3              0.313
    v5T3              0.192
    v6T3              0.737
anova(metricEstimates2, scalarEstimates1)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                  Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)    
metricEstimates2 123 9003.3 9202.5 303.25                                  
scalarEstimates1 132 9037.7 9209.7 355.59     55.106       9  1.162e-08 ***
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
anova(configuralEstimates, scalarEstimates1)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                     Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)    
configuralEstimates 114 9010.6 9236.9 292.51                                  
scalarEstimates1    132 9037.7 9209.7 355.59     58.816      18  3.174e-06 ***
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Does the full scalar model (3a) fit worse than the partial metric model (2b)? Yes, −2∆LL(df=9) = 55.13, p <.01. A look at the modification indices reveals a number of items with large values. We will pick the intercept from item2 at time1 to free.

#get modification indices for all parameters:
scalarMI1 = modificationindices(scalarEstimates1, free.remove = FALSE, maximum.number = 10000)
#restrict output to only factor loading parameters
scalarMI1a = scalarMI1[which(scalarMI1$op == "~1"),]
scalarMI1a[order(-scalarMI1a$mi),]
     lhs op rhs     mi mi.scaled    epc sepc.lv sepc.all sepc.nox
20  v2T1 ~1     12.968    12.491 -0.814  -0.814   -0.221   -0.221
29  v5T2 ~1     12.432    11.975 -0.364  -0.364   -0.147   -0.147
23  v5T1 ~1      8.446     8.136  0.219   0.219    0.134    0.134
22  v4T1 ~1      8.406     8.097  0.519   0.519    0.160    0.160
28  v4T2 ~1      4.843     4.665 -0.335  -0.335   -0.104   -0.104
26  v2T2 ~1      4.608     4.438  0.376   0.376    0.115    0.115
24  v6T1 ~1      1.667     1.606 -0.120  -0.120   -0.060   -0.060
33  v3T3 ~1      1.131     1.089  0.134   0.134    0.055    0.055
31  v1T3 ~1      0.702     0.676 -0.085  -0.085   -0.032   -0.032
25  v1T2 ~1      0.657     0.633  0.079   0.079    0.027    0.027
30  v6T2 ~1      0.631     0.607  0.058   0.058    0.030    0.030
32  v2T3 ~1      0.563     0.542  0.153   0.153    0.051    0.051
21  v3T1 ~1      0.362     0.349 -0.073  -0.073   -0.029   -0.029
35  v5T3 ~1      0.230     0.221 -0.053  -0.053   -0.026   -0.026
27  v3T2 ~1      0.151     0.146 -0.043  -0.043   -0.017   -0.017
34  v4T3 ~1      0.104     0.100 -0.059  -0.059   -0.019   -0.019
36  v6T3 ~1      0.049     0.047  0.017   0.017    0.010    0.010
78 Time3 ~1      0.000     0.000  0.000   0.000    0.000    0.000
77 Time2 ~1      0.000     0.000  0.000   0.000    0.000    0.000
19  v1T1 ~1      0.000     0.000  0.000   0.000    0.000    0.000
scalarSyntax2 = "
#===================================================================================================
#Factor loadings constrained across groups except non-invariant ones
Time1 =~ L1T1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2 + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3 + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all constrained across groups except non-invariant ones ****
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3*1; v4T1 ~ I4*1; v5T1 ~ I5*1; v6T1 ~ I6*1; 
v1T2 ~ I1*1;   v2T2 ~ I2*1;  v3T2 ~ I3*1; v4T2 ~ I4*1; v5T2 ~ I5*1; v6T2 ~ I6*1; 
v1T3 ~ I1*1;   v2T3 ~ I2*1;  v3T3 ~ I3*1; v4T3 ~ I4*1; v5T3 ~ I5*1; v6T3 ~ I6*1; 
#===================================================================================================
#Redidual variances all freely estimated in each group with labels
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3T1*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5T1*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1T2*v1T2; v2T2 ~~ E2T2*v2T2;  v3T2 ~~ E3T2*v3T2; v4T2 ~~ E4T2*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6T2*v6T2;
v1T3 ~~ E1T3*v1T3; v2T3 ~~ E2T3*v2T3;  v3T3 ~~ E3T3*v3T3; v4T3 ~~ E4T3*v4T3; v5T3 ~~ E5T3*v5T3; v6T3 ~~ E6T3*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others
Time1 ~~ 1*Time1
Time2 ~~ Time2
Time3 ~~ Time3
#===================================================================================================
#Factor mean fixed to zero for identification first group, estimated in others ****
Time1 ~ 0
Time2 ~ 1
Time3 ~ 1
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
"
scalarEstimates2 = lavaan(model = scalarSyntax2, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(scalarEstimates2, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 116 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              339.321     327.268
  Degrees of freedom                               131         131
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.037
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.898       0.887
  Tucker-Lewis Index (TLI)                       0.881       0.869

  Robust Comparative Fit Index (CFI)                         0.899
  Robust Tucker-Lewis Index (TLI)                            0.882

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4453.706   -4453.706
  Scaling correction factor                                  1.159
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         58          58
  Akaike (AIC)                                9023.412    9023.412
  Bayesian (BIC)                              9198.414    9198.414
  Sample-size adjusted Bayesian (BIC)         9014.850    9014.850

Root Mean Square Error of Approximation:

  RMSEA                                          0.103       0.100
  90 Percent Confidence Interval          0.089  0.116       0.086  0.113
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.101
  90 Percent Confidence Interval                             0.088  0.115

Standardized Root Mean Square Residual:

  SRMR                                           0.092       0.092

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.227    0.263   12.260    0.000    3.227    0.990
    v2T1      (L2)    1.977    0.201    9.826    0.000    1.977    0.558
    v3T1      (L3)    2.023    0.195   10.359    0.000    2.023    0.789
    v4T1      (L4)    1.829    0.232    7.889    0.000    1.829    0.562
    v5T1      (L5)    0.927    0.150    6.165    0.000    0.927    0.564
    v6T1      (L6)    1.511    0.130   11.634    0.000    1.511    0.756
  Time2 =~                                                              
    v1T2      (L1)    2.652    0.230   11.505    0.000    2.836    0.965
    v2T2      (L2)    1.977    0.201    9.826    0.000    2.114    0.658
    v3T2      (L3)    2.023    0.195   10.359    0.000    2.163    0.828
    v4T2      (L4)    1.829    0.232    7.889    0.000    1.956    0.602
    v5T2      (L5)    0.927    0.150    6.165    0.000    0.991    0.401
    v6T2      (L6)    1.511    0.130   11.634    0.000    1.616    0.841
  Time3 =~                                                              
    v1T3      (L1)    2.652    0.230   11.505    0.000    2.559    0.961
    v2T3      (L2)    1.977    0.201    9.826    0.000    1.907    0.644
    v3T3      (L3)    2.023    0.195   10.359    0.000    1.952    0.790
    v4T3      (L4)    1.829    0.232    7.889    0.000    1.765    0.568
    v5T3      (L5)    0.927    0.150    6.165    0.000    0.894    0.450
    v6T3      (L6)    1.511    0.130   11.634    0.000    1.458    0.858

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.196    0.250   -0.783    0.434   -0.196   -0.543
   .v1T3   (C1T13)    0.009    0.239    0.037    0.971    0.009    0.026
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.133    0.231    0.574    0.566    0.133    0.234
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.948    0.679    5.818    0.000    3.948    0.554
   .v2T3   (C2T13)    2.234    0.799    2.794    0.005    2.234    0.335
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.144    0.563    3.804    0.000    2.144    0.391
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.989    0.295    3.349    0.001    0.989    0.429
   .v3T3   (C3T13)    1.091    0.292    3.732    0.000    1.091    0.457
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.171    0.319    3.673    0.000    1.171    0.527
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.665    0.840    5.550    0.000    4.665    0.668
   .v4T3   (C4T13)    3.742    1.019    3.674    0.000    3.742    0.543
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.561    0.805    5.667    0.000    4.561    0.688
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.417    0.826    2.927    0.003    2.417    0.788
   .v5T3   (C5T13)    1.475    0.480    3.071    0.002    1.475    0.613
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    3.147    0.914    3.443    0.001    3.147    0.785
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.813    0.168    4.838    0.000    0.813    0.598
   .v6T3   (C6T13)    0.571    0.177    3.232    0.001    0.571    0.499
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.522    0.134    3.902    0.000    0.522    0.575
  Time1 ~~                                                              
    Time2             0.841    0.078   10.747    0.000    0.787    0.787
    Time3             0.681    0.122    5.582    0.000    0.706    0.706
  Time2 ~~                                                              
    Time3             0.695    0.125    5.554    0.000    0.674    0.674

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.090    0.274   58.695    0.000   16.090    4.935
   .v2T1    (I2T1)    8.672    0.294   29.525    0.000    8.672    2.446
   .v3T1      (I3)   12.100    0.226   53.558    0.000   12.100    4.719
   .v4T1      (I4)   -3.329    0.254  -13.103    0.000   -3.329   -1.022
   .v5T1      (I5)   -1.193    0.124   -9.630    0.000   -1.193   -0.726
   .v6T1      (I6)   -2.699    0.166  -16.286    0.000   -2.699   -1.350
   .v1T2      (I1)   16.738    0.275   60.784    0.000   16.738    5.696
   .v2T2      (I2)    9.645    0.261   36.936    0.000    9.645    3.000
   .v3T2      (I3)   12.100    0.226   53.558    0.000   12.100    4.633
   .v4T2      (I4)   -3.329    0.254  -13.103    0.000   -3.329   -1.025
   .v5T2      (I5)   -1.193    0.124   -9.630    0.000   -1.193   -0.483
   .v6T2      (I6)   -2.699    0.166  -16.286    0.000   -2.699   -1.405
   .v1T3      (I1)   16.738    0.275   60.784    0.000   16.738    6.287
   .v2T3      (I2)    9.645    0.261   36.936    0.000    9.645    3.257
   .v3T3      (I3)   12.100    0.226   53.558    0.000   12.100    4.895
   .v4T3      (I4)   -3.329    0.254  -13.103    0.000   -3.329   -1.071
   .v5T3      (I5)   -1.193    0.124   -9.630    0.000   -1.193   -0.600
   .v6T3      (I6)   -2.699    0.166  -16.286    0.000   -2.699   -1.589
    Time1             0.000                               0.000    0.000
    Time2             0.171    0.079    2.162    0.031    0.160    0.160
    Time3             0.399    0.080    4.963    0.000    0.413    0.413

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.220    0.387    0.568    0.570    0.220    0.021
   .v2T1    (E2T1)    8.663    1.028    8.430    0.000    8.663    0.689
   .v3T1    (E3T1)    2.484    0.406    6.123    0.000    2.484    0.378
   .v4T1    (E4T1)    7.258    1.013    7.163    0.000    7.258    0.684
   .v5T1    (E5T1)    1.841    0.456    4.041    0.000    1.841    0.682
   .v6T1    (E6T1)    1.713    0.253    6.769    0.000    1.713    0.429
   .v1T2    (E1T2)    0.594    0.270    2.203    0.028    0.594    0.069
   .v2T2    (E2T2)    5.864    0.600    9.771    0.000    5.864    0.568
   .v3T2    (E3T2)    2.143    0.352    6.093    0.000    2.143    0.314
   .v4T2    (E4T2)    6.714    0.963    6.972    0.000    6.714    0.637
   .v5T2    (E5T2)    5.115    1.625    3.147    0.002    5.115    0.839
   .v6T2    (E6T2)    1.080    0.164    6.593    0.000    1.080    0.293
   .v1T3    (E1T3)    0.541    0.310    1.743    0.081    0.541    0.076
   .v2T3    (E2T3)    5.132    0.789    6.504    0.000    5.132    0.585
   .v3T3    (E3T3)    2.301    0.419    5.497    0.000    2.301    0.377
   .v4T3    (E4T3)    6.544    1.123    5.828    0.000    6.544    0.678
   .v5T3    (E5T3)    3.145    0.863    3.644    0.000    3.145    0.797
   .v6T3    (E6T3)    0.762    0.169    4.498    0.000    0.762    0.264
    Time1             1.000                               1.000    1.000
    Time2             1.143    0.183    6.261    0.000    1.000    1.000
    Time3             0.931    0.153    6.089    0.000    1.000    1.000

R-Square:
                   Estimate
    v1T1              0.979
    v2T1              0.311
    v3T1              0.622
    v4T1              0.316
    v5T1              0.318
    v6T1              0.571
    v1T2              0.931
    v2T2              0.432
    v3T2              0.686
    v4T2              0.363
    v5T2              0.161
    v6T2              0.707
    v1T3              0.924
    v2T3              0.415
    v3T3              0.623
    v4T3              0.322
    v5T3              0.203
    v6T3              0.736
anova(metricEstimates2, scalarEstimates2)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                  Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)    
metricEstimates2 123 9003.3 9202.5 303.25                                  
scalarEstimates2 131 9023.4 9198.4 339.32     39.321       8  4.285e-06 ***
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
anova(configuralEstimates, scalarEstimates2)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                     Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)    
configuralEstimates 114 9010.6 9236.9 292.51                                  
scalarEstimates2    131 9023.4 9198.4 339.32     43.975      17  0.0003454 ***
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Does the partial scalar model fit worse than the partial metric model? Yes, −2∆LL(df=8) = 39.321, p <.01. A look at the modification indices reveals a number of items with large values. We will pick the intercept from item5 at time2 to free.

#get modification indices for all parameters:
scalarMI2 = modificationindices(scalarEstimates2, free.remove = FALSE, maximum.number = 10000)
#restrict output to only item intercept parameters:
scalarMI2a = scalarMI2[which(scalarMI2$op == "~1"),]
scalarMI2a[order(-scalarMI2a$mi),]
     lhs op rhs     mi mi.scaled    epc sepc.lv sepc.all sepc.nox
29  v5T2 ~1     11.097    10.703 -0.340  -0.340   -0.138   -0.138
23  v5T1 ~1      7.254     6.997  0.202   0.202    0.123    0.123
22  v4T1 ~1      6.089     5.873  0.436   0.436    0.134    0.134
24  v6T1 ~1      4.979     4.802 -0.210  -0.210   -0.105   -0.105
28  v4T2 ~1      3.566     3.440 -0.285  -0.285   -0.088   -0.088
21  v3T1 ~1      1.977     1.907 -0.173  -0.173   -0.068   -0.068
33  v3T3 ~1      1.817     1.753  0.171   0.171    0.069    0.069
30  v6T2 ~1      1.711     1.650  0.096   0.096    0.050    0.050
31  v1T3 ~1      0.886     0.854 -0.095  -0.095   -0.036   -0.036
25  v1T2 ~1      0.833     0.803  0.089   0.089    0.030    0.030
36  v6T3 ~1      0.191     0.184  0.033   0.033    0.019    0.019
35  v5T3 ~1      0.135     0.130 -0.040  -0.040   -0.020   -0.020
34  v4T3 ~1      0.070     0.068 -0.049  -0.049   -0.016   -0.016
27  v3T2 ~1      0.008     0.008  0.010   0.010    0.004    0.004
32  v2T3 ~1      0.000     0.000  0.004   0.004    0.001    0.001
26  v2T2 ~1      0.000     0.000 -0.003  -0.003   -0.001   -0.001
77 Time2 ~1      0.000     0.000  0.000   0.000    0.000    0.000
78 Time3 ~1      0.000     0.000  0.000   0.000    0.000    0.000
19  v1T1 ~1      0.000     0.000  0.000   0.000    0.000    0.000
20  v2T1 ~1      0.000     0.000  0.000   0.000    0.000    0.000
scalarSyntax3 = "
#===================================================================================================
#Factor loadings constrained across groups except non-invariant ones
Time1 =~ L1T1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2 + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3 + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all constrained across groups except non-invariant ones ****
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3*1; v4T1 ~ I4*1; v5T1 ~ I5*1; v6T1 ~ I6*1; 
v1T2 ~ I1*1;   v2T2 ~ I2*1;  v3T2 ~ I3*1; v4T2 ~ I4*1; v5T2 ~ I5T2*1; v6T2 ~ I6*1; 
v1T3 ~ I1*1;   v2T3 ~ I2*1;  v3T3 ~ I3*1; v4T3 ~ I4*1; v5T3 ~ I5*1; v6T3 ~ I6*1; 
#===================================================================================================
#Redidual variances all freely estimated in each group with labels
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3T1*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5T1*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1T2*v1T2; v2T2 ~~ E2T2*v2T2;  v3T2 ~~ E3T2*v3T2; v4T2 ~~ E4T2*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6T2*v6T2;
v1T3 ~~ E1T3*v1T3; v2T3 ~~ E2T3*v2T3;  v3T3 ~~ E3T3*v3T3; v4T3 ~~ E4T3*v4T3; v5T3 ~~ E5T3*v5T3; v6T3 ~~ E6T3*v6T3; 
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others
Time1 ~~ 1*Time1
Time2 ~~ Time2
Time3 ~~ Time3
#===================================================================================================
#Factor mean fixed to zero for identification first group, estimated in others ****
Time1 ~ 0
Time2 ~ 1
Time3 ~ 1
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
"
scalarEstimates3 = lavaan(model = scalarSyntax3, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(scalarEstimates3, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 121 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              324.707     311.362
  Degrees of freedom                               130         130
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.043
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.905       0.896
  Tucker-Lewis Index (TLI)                       0.888       0.878

  Robust Comparative Fit Index (CFI)                         0.906
  Robust Tucker-Lewis Index (TLI)                            0.890

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4446.399   -4446.399
  Scaling correction factor                                  1.162
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         59          59
  Akaike (AIC)                                9010.798    9010.798
  Bayesian (BIC)                              9188.817    9188.817
  Sample-size adjusted Bayesian (BIC)         9002.088    9002.088

Root Mean Square Error of Approximation:

  RMSEA                                          0.100       0.096
  90 Percent Confidence Interval          0.086  0.113       0.083  0.110
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.098
  90 Percent Confidence Interval                             0.084  0.112

Standardized Root Mean Square Residual:

  SRMR                                           0.088       0.088

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.226    0.263   12.275    0.000    3.226    0.989
    v2T1      (L2)    1.980    0.200    9.888    0.000    1.980    0.558
    v3T1      (L3)    2.021    0.194   10.423    0.000    2.021    0.790
    v4T1      (L4)    1.814    0.231    7.849    0.000    1.814    0.558
    v5T1      (L5)    0.916    0.142    6.456    0.000    0.916    0.561
    v6T1      (L6)    1.513    0.128   11.821    0.000    1.513    0.757
  Time2 =~                                                              
    v1T2      (L1)    2.660    0.231   11.533    0.000    2.840    0.966
    v2T2      (L2)    1.980    0.200    9.888    0.000    2.114    0.657
    v3T2      (L3)    2.021    0.194   10.423    0.000    2.158    0.827
    v4T2      (L4)    1.814    0.231    7.849    0.000    1.937    0.599
    v5T2      (L5)    0.916    0.142    6.456    0.000    0.978    0.412
    v6T2      (L6)    1.513    0.128   11.821    0.000    1.615    0.841
  Time3 =~                                                              
    v1T3      (L1)    2.660    0.231   11.533    0.000    2.561    0.961
    v2T3      (L2)    1.980    0.200    9.888    0.000    1.906    0.644
    v3T3      (L3)    2.021    0.194   10.423    0.000    1.946    0.789
    v4T3      (L4)    1.814    0.231    7.849    0.000    1.747    0.565
    v5T3      (L5)    0.916    0.142    6.456    0.000    0.882    0.449
    v6T3      (L6)    1.513    0.128   11.821    0.000    1.457    0.858

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.201    0.252   -0.796    0.426   -0.201   -0.556
   .v1T3   (C1T13)    0.014    0.241    0.056    0.955    0.014    0.039
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.134    0.231    0.579    0.562    0.134    0.239
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.951    0.679    5.815    0.000    3.951    0.554
   .v2T3   (C2T13)    2.223    0.799    2.781    0.005    2.223    0.334
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.135    0.563    3.790    0.000    2.135    0.389
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.992    0.296    3.358    0.001    0.992    0.430
   .v3T3   (C3T13)    1.092    0.292    3.743    0.000    1.092    0.458
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.171    0.319    3.671    0.000    1.171    0.526
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.635    0.838    5.529    0.000    4.635    0.663
   .v4T3   (C4T13)    3.720    1.019    3.650    0.000    3.720    0.540
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.538    0.800    5.675    0.000    4.538    0.686
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.342    0.761    3.079    0.002    2.342    0.799
   .v5T3   (C5T13)    1.423    0.446    3.188    0.001    1.423    0.599
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    2.909    0.802    3.629    0.000    2.909    0.765
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.820    0.167    4.912    0.000    0.820    0.604
   .v6T3   (C6T13)    0.572    0.176    3.246    0.001    0.572    0.503
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.522    0.134    3.902    0.000    0.522    0.575
  Time1 ~~                                                              
    Time2             0.840    0.077   10.902    0.000    0.786    0.786
    Time3             0.679    0.122    5.564    0.000    0.705    0.705
  Time2 ~~                                                              
    Time3             0.692    0.125    5.533    0.000    0.673    0.673

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.085    0.275   58.539    0.000   16.085    4.934
   .v2T1    (I2T1)    8.677    0.293   29.587    0.000    8.677    2.446
   .v3T1      (I3)   12.062    0.225   53.554    0.000   12.062    4.712
   .v4T1      (I4)   -3.359    0.259  -12.963    0.000   -3.359   -1.033
   .v5T1      (I5)   -1.353    0.141   -9.604    0.000   -1.353   -0.828
   .v6T1      (I6)   -2.735    0.165  -16.560    0.000   -2.735   -1.369
   .v1T2      (I1)   16.664    0.276   60.330    0.000   16.664    5.667
   .v2T2      (I2)    9.589    0.261   36.774    0.000    9.589    2.982
   .v3T2      (I3)   12.062    0.225   53.554    0.000   12.062    4.622
   .v4T2      (I4)   -3.359    0.259  -12.963    0.000   -3.359   -1.039
   .v5T2    (I5T2)   -1.779    0.214   -8.299    0.000   -1.779   -0.748
   .v6T2      (I6)   -2.735    0.165  -16.560    0.000   -2.735   -1.423
   .v1T3      (I1)   16.664    0.276   60.330    0.000   16.664    6.254
   .v2T3      (I2)    9.589    0.261   36.774    0.000    9.589    3.240
   .v3T3      (I3)   12.062    0.225   53.554    0.000   12.062    4.887
   .v4T3      (I4)   -3.359    0.259  -12.963    0.000   -3.359   -1.086
   .v5T3      (I5)   -1.353    0.141   -9.604    0.000   -1.353   -0.689
   .v6T3      (I6)   -2.735    0.165  -16.560    0.000   -2.735   -1.610
    Time1             0.000                               0.000    0.000
    Time2             0.205    0.076    2.691    0.007    0.192    0.192
    Time3             0.419    0.080    5.223    0.000    0.435    0.435

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.225    0.386    0.583    0.560    0.225    0.021
   .v2T1    (E2T1)    8.663    1.029    8.419    0.000    8.663    0.688
   .v3T1    (E3T1)    2.468    0.398    6.200    0.000    2.468    0.377
   .v4T1    (E4T1)    7.281    1.016    7.169    0.000    7.281    0.689
   .v5T1    (E5T1)    1.831    0.442    4.140    0.000    1.831    0.686
   .v6T1    (E6T1)    1.703    0.249    6.832    0.000    1.703    0.427
   .v1T2    (E1T2)    0.580    0.269    2.158    0.031    0.580    0.067
   .v2T2    (E2T2)    5.872    0.601    9.773    0.000    5.872    0.568
   .v3T2    (E3T2)    2.154    0.352    6.111    0.000    2.154    0.316
   .v4T2    (E4T2)    6.706    0.962    6.973    0.000    6.706    0.641
   .v5T2    (E5T2)    4.691    1.426    3.290    0.001    4.691    0.831
   .v6T2    (E6T2)    1.082    0.164    6.582    0.000    1.082    0.293
   .v1T3    (E1T3)    0.538    0.314    1.714    0.087    0.538    0.076
   .v2T3    (E2T3)    5.126    0.788    6.506    0.000    5.126    0.585
   .v3T3    (E3T3)    2.304    0.418    5.507    0.000    2.304    0.378
   .v4T3    (E4T3)    6.524    1.117    5.839    0.000    6.524    0.681
   .v5T3    (E5T3)    3.080    0.833    3.699    0.000    3.080    0.798
   .v6T3    (E6T3)    0.762    0.168    4.522    0.000    0.762    0.264
    Time1             1.000                               1.000    1.000
    Time2             1.140    0.179    6.374    0.000    1.000    1.000
    Time3             0.927    0.154    6.028    0.000    1.000    1.000

R-Square:
                   Estimate
    v1T1              0.979
    v2T1              0.312
    v3T1              0.623
    v4T1              0.311
    v5T1              0.314
    v6T1              0.573
    v1T2              0.933
    v2T2              0.432
    v3T2              0.684
    v4T2              0.359
    v5T2              0.169
    v6T2              0.707
    v1T3              0.924
    v2T3              0.415
    v3T3              0.622
    v4T3              0.319
    v5T3              0.202
    v6T3              0.736
anova(metricEstimates2, scalarEstimates3)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                  Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)   
metricEstimates2 123 9003.3 9202.5 303.25                                 
scalarEstimates3 130 9010.8 9188.8 324.71     21.199       7   0.003486 **
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
anova(configuralEstimates, scalarEstimates3)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                     Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)  
configuralEstimates 114 9010.6 9236.9 292.51                                
scalarEstimates3    130 9010.8 9188.8 324.71      28.87      16    0.02483 *
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Does the partial scalar model fit worse than the partial metric model? Yes, −2∆LL(df=7) = 21.199, p <.01. A look at the modification indices reveals several items with large values. We will pick the intercept from item4 at time1 to free.

#get modification indices for all parameters:
scalarMI3 = modificationindices(scalarEstimates3, free.remove = FALSE, maximum.number = 10000)
#restrict output to only item intercept parameters:
scalarMI3a = scalarMI3[which(scalarMI3$op == "~1"),]
scalarMI3a[order(-scalarMI3a$mi),]
     lhs op rhs    mi mi.scaled    epc sepc.lv sepc.all sepc.nox
22  v4T1 ~1     7.360     7.057  0.483   0.483    0.148    0.148
28  v4T2 ~1     4.582     4.394 -0.324  -0.324   -0.100   -0.100
35  v5T3 ~1     4.389     4.209 -0.235  -0.235   -0.120   -0.120
24  v6T1 ~1     3.049     2.923 -0.163  -0.163   -0.082   -0.082
23  v5T1 ~1     1.858     1.782  0.099   0.099    0.061    0.061
33  v3T3 ~1     1.838     1.762  0.172   0.172    0.070    0.070
21  v3T1 ~1     1.004     0.963 -0.123  -0.123   -0.048   -0.048
30  v6T2 ~1     0.749     0.718  0.063   0.063    0.033    0.033
31  v1T3 ~1     0.273     0.262 -0.053  -0.053   -0.020   -0.020
36  v6T3 ~1     0.260     0.250  0.038   0.038    0.022    0.022
25  v1T2 ~1     0.255     0.245  0.049   0.049    0.017    0.017
27  v3T2 ~1     0.078     0.075 -0.031  -0.031   -0.012   -0.012
34  v4T3 ~1     0.042     0.040 -0.038  -0.038   -0.012   -0.012
32  v2T3 ~1     0.011     0.011  0.021   0.021    0.007    0.007
26  v2T2 ~1     0.008     0.008 -0.015  -0.015   -0.005   -0.005
29  v5T2 ~1     0.000     0.000  0.000   0.000    0.000    0.000
19  v1T1 ~1     0.000     0.000  0.000   0.000    0.000    0.000
77 Time2 ~1     0.000     0.000  0.000   0.000    0.000    0.000
78 Time3 ~1     0.000     0.000  0.000   0.000    0.000    0.000
20  v2T1 ~1     0.000     0.000  0.000   0.000    0.000    0.000
scalarSyntax4 = "
#===================================================================================================
#Factor loadings constrained across groups except non-invariant ones
Time1 =~ L1T1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2 + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3 + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all constrained across groups except non-invariant ones ****
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3*1; v4T1 ~ I4T1*1; v5T1 ~ I5*1; v6T1 ~ I6*1; 
v1T2 ~ I1*1;   v2T2 ~ I2*1;  v3T2 ~ I3*1; v4T2 ~ I4*1; v5T2 ~ I5T2*1; v6T2 ~ I6*1; 
v1T3 ~ I1*1;   v2T3 ~ I2*1;  v3T3 ~ I3*1; v4T3 ~ I4*1; v5T3 ~ I5*1; v6T3 ~ I6*1; 
#===================================================================================================
#Redidual variances all freely estimated in each group with labels
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3T1*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5T1*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1T2*v1T2; v2T2 ~~ E2T2*v2T2;  v3T2 ~~ E3T2*v3T2; v4T2 ~~ E4T2*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6T2*v6T2;
v1T3 ~~ E1T3*v1T3; v2T3 ~~ E2T3*v2T3;  v3T3 ~~ E3T3*v3T3; v4T3 ~~ E4T3*v4T3; v5T3 ~~ E5T3*v5T3; v6T3 ~~ E6T3*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others
Time1 ~~ 1*Time1
Time2 ~~ Time2
Time3 ~~ Time3
#===================================================================================================
#Factor mean fixed to zero for identification first group, estimated in others ****
Time1 ~ 0
Time2 ~ 1
Time3 ~ 1
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
"
scalarEstimates4 = lavaan(model = scalarSyntax4, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(scalarEstimates4, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 110 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              314.564     302.389
  Degrees of freedom                               129         129
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.040
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.909       0.901
  Tucker-Lewis Index (TLI)                       0.892       0.882

  Robust Comparative Fit Index (CFI)                         0.911
  Robust Tucker-Lewis Index (TLI)                            0.894

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4441.327   -4441.327
  Scaling correction factor                                  1.179
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         60          60
  Akaike (AIC)                                9002.655    9002.655
  Bayesian (BIC)                              9183.692    9183.692
  Sample-size adjusted Bayesian (BIC)         8993.798    8993.798

Root Mean Square Error of Approximation:

  RMSEA                                          0.098       0.094
  90 Percent Confidence Interval          0.084  0.111       0.081  0.108
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.096
  90 Percent Confidence Interval                             0.082  0.110

Standardized Root Mean Square Residual:

  SRMR                                           0.092       0.092

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.226    0.262   12.322    0.000    3.226    0.990
    v2T1      (L2)    1.977    0.200    9.905    0.000    1.977    0.558
    v3T1      (L3)    2.009    0.194   10.340    0.000    2.009    0.788
    v4T1      (L4)    1.916    0.226    8.490    0.000    1.916    0.582
    v5T1      (L5)    0.906    0.141    6.424    0.000    0.906    0.556
    v6T1      (L6)    1.505    0.127   11.899    0.000    1.505    0.756
  Time2 =~                                                              
    v1T2      (L1)    2.664    0.231   11.557    0.000    2.843    0.966
    v2T2      (L2)    1.977    0.200    9.905    0.000    2.110    0.656
    v3T2      (L3)    2.009    0.194   10.340    0.000    2.143    0.824
    v4T2      (L4)    1.916    0.226    8.490    0.000    2.045    0.618
    v5T2      (L5)    0.906    0.141    6.424    0.000    0.967    0.408
    v6T2      (L6)    1.505    0.127   11.899    0.000    1.606    0.839
  Time3 =~                                                              
    v1T3      (L1)    2.664    0.231   11.557    0.000    2.562    0.962
    v2T3      (L2)    1.977    0.200    9.905    0.000    1.902    0.643
    v3T3      (L3)    2.009    0.194   10.340    0.000    1.932    0.786
    v4T3      (L4)    1.916    0.226    8.490    0.000    1.843    0.583
    v5T3      (L5)    0.906    0.141    6.424    0.000    0.871    0.443
    v6T3      (L6)    1.505    0.127   11.899    0.000    1.448    0.855

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.204    0.251   -0.814    0.416   -0.204   -0.578
   .v1T3   (C1T13)    0.015    0.240    0.061    0.951    0.015    0.043
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.134    0.231    0.580    0.562    0.134    0.243
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.954    0.679    5.820    0.000    3.954    0.554
   .v2T3   (C2T13)    2.222    0.798    2.784    0.005    2.222    0.333
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.133    0.564    3.782    0.000    2.133    0.388
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.994    0.294    3.382    0.001    0.994    0.431
   .v3T3   (C3T13)    1.105    0.290    3.813    0.000    1.105    0.464
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.168    0.319    3.663    0.000    1.168    0.523
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.809    0.851    5.649    0.000    4.809    0.691
   .v4T3   (C4T13)    3.881    1.032    3.762    0.000    3.881    0.564
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.657    0.831    5.602    0.000    4.657    0.697
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.344    0.761    3.081    0.002    2.344    0.799
   .v5T3   (C5T13)    1.423    0.448    3.174    0.002    1.423    0.596
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    2.918    0.805    3.627    0.000    2.918    0.764
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.826    0.165    5.019    0.000    0.826    0.609
   .v6T3   (C6T13)    0.579    0.176    3.293    0.001    0.579    0.507
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.525    0.134    3.933    0.000    0.525    0.576
  Time1 ~~                                                              
    Time2             0.838    0.077   10.916    0.000    0.786    0.786
    Time3             0.677    0.123    5.525    0.000    0.704    0.704
  Time2 ~~                                                              
    Time3             0.689    0.126    5.491    0.000    0.672    0.672

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.084    0.275   58.538    0.000   16.084    4.933
   .v2T1    (I2T1)    8.678    0.293   29.586    0.000    8.678    2.447
   .v3T1      (I3)   11.996    0.222   53.986    0.000   11.996    4.707
   .v4T1    (I4T1)   -3.020    0.267  -11.307    0.000   -3.020   -0.917
   .v5T1      (I5)   -1.360    0.142   -9.574    0.000   -1.360   -0.835
   .v6T1      (I6)   -2.802    0.161  -17.432    0.000   -2.802   -1.408
   .v1T2      (I1)   16.526    0.273   60.493    0.000   16.526    5.618
   .v2T2      (I2)    9.489    0.257   36.850    0.000    9.489    2.952
   .v3T2      (I3)   11.996    0.222   53.986    0.000   11.996    4.615
   .v4T2      (I4)   -3.668    0.284  -12.896    0.000   -3.668   -1.109
   .v5T2    (I5T2)   -1.816    0.219   -8.277    0.000   -1.816   -0.766
   .v6T2      (I6)   -2.802    0.161  -17.432    0.000   -2.802   -1.464
   .v1T3      (I1)   16.526    0.273   60.493    0.000   16.526    6.203
   .v2T3      (I2)    9.489    0.257   36.850    0.000    9.489    3.208
   .v3T3      (I3)   11.996    0.222   53.986    0.000   11.996    4.884
   .v4T3      (I4)   -3.668    0.284  -12.896    0.000   -3.668   -1.159
   .v5T3      (I5)   -1.360    0.142   -9.574    0.000   -1.360   -0.692
   .v6T3      (I6)   -2.802    0.161  -17.432    0.000   -2.802   -1.656
    Time1             0.000                               0.000    0.000
    Time2             0.257    0.075    3.432    0.001    0.241    0.241
    Time3             0.468    0.085    5.506    0.000    0.487    0.487

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.219    0.377    0.580    0.562    0.219    0.021
   .v2T1    (E2T1)    8.669    1.027    8.437    0.000    8.669    0.689
   .v3T1    (E3T1)    2.462    0.387    6.362    0.000    2.462    0.379
   .v4T1    (E4T1)    7.173    1.023    7.014    0.000    7.173    0.661
   .v5T1    (E5T1)    1.833    0.443    4.142    0.000    1.833    0.691
   .v6T1    (E6T1)    1.696    0.244    6.960    0.000    1.696    0.428
   .v1T2    (E1T2)    0.571    0.267    2.139    0.032    0.571    0.066
   .v2T2    (E2T2)    5.882    0.603    9.751    0.000    5.882    0.569
   .v3T2    (E3T2)    2.163    0.352    6.145    0.000    2.163    0.320
   .v4T2    (E4T2)    6.761    0.970    6.967    0.000    6.761    0.618
   .v5T2    (E5T2)    4.693    1.424    3.296    0.001    4.693    0.834
   .v6T2    (E6T2)    1.084    0.164    6.600    0.000    1.084    0.296
   .v1T3    (E1T3)    0.532    0.316    1.685    0.092    0.532    0.075
   .v2T3    (E2T3)    5.134    0.788    6.513    0.000    5.134    0.587
   .v3T3    (E3T3)    2.303    0.416    5.534    0.000    2.303    0.382
   .v4T3    (E4T3)    6.610    1.131    5.844    0.000    6.610    0.661
   .v5T3    (E5T3)    3.106    0.841    3.692    0.000    3.106    0.804
   .v6T3    (E6T3)    0.768    0.169    4.540    0.000    0.768    0.268
    Time1             1.000                               1.000    1.000
    Time2             1.138    0.178    6.395    0.000    1.000    1.000
    Time3             0.925    0.154    6.024    0.000    1.000    1.000

R-Square:
                   Estimate
    v1T1              0.979
    v2T1              0.311
    v3T1              0.621
    v4T1              0.339
    v5T1              0.309
    v6T1              0.572
    v1T2              0.934
    v2T2              0.431
    v3T2              0.680
    v4T2              0.382
    v5T2              0.166
    v6T2              0.704
    v1T3              0.925
    v2T3              0.413
    v3T3              0.618
    v4T3              0.339
    v5T3              0.196
    v6T3              0.732
anova(metricEstimates2, scalarEstimates4)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                  Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)  
metricEstimates2 123 9003.3 9202.5 303.25                                
scalarEstimates4 129 9002.7 9183.7 314.56     11.895       6    0.06435 .
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
anova(configuralEstimates, scalarEstimates4)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                     Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)
configuralEstimates 114 9010.6 9236.9 292.51                              
scalarEstimates4    129 9002.7 9183.7 314.56     20.089      15     0.1685

We finally see our likelihood ratio test cooperate and consider this to be the model to move forward with. Next is testing residual invariance.

Residual Variance Invariance Model (error variances held equal for all except non-invariant items)

residVarSyntax1 = "
#===================================================================================================
#Factor loadings constrained across groups except non-invariant ones
Time1 =~ L1T1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2 + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3 + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all constrained across groups except non-invariant ones
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3*1; v4T1 ~ I4T1*1; v5T1 ~ I5*1; v6T1 ~ I6*1; 
v1T2 ~ I1*1;   v2T2 ~ I2*1;  v3T2 ~ I3*1; v4T2 ~ I4*1; v5T2 ~ I5T2*1; v6T2 ~ I6*1; 
v1T3 ~ I1*1;   v2T3 ~ I2*1;  v3T3 ~ I3*1; v4T3 ~ I4*1; v5T3 ~ I5*1; v6T3 ~ I6*1; 
#===================================================================================================
#Redidual variances all constrained in each group except non-invariant ones ****
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5*v5T1; v6T1 ~~ E6*v6T1;
v1T2 ~~ E1*v1T2; v2T2 ~~ E2*v2T2;  v3T2 ~~ E3*v3T2; v4T2 ~~ E4*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6*v6T2;
v1T3 ~~ E1*v1T3; v2T3 ~~ E2*v2T3;  v3T3 ~~ E3*v3T3; v4T3 ~~ E4*v4T3; v5T3 ~~ E5*v5T3; v6T3 ~~ E6*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others
Time1 ~~ 1*Time1
Time2 ~~ Time2
Time3 ~~ Time3
#===================================================================================================
#Factor mean fixed to zero for identification first group, estimated in others
Time1 ~ 0
Time2 ~ 1
Time3 ~ 1
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
"
residVarEstimates1 = lavaan(model = residVarSyntax1, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(residVarEstimates1, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 114 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              344.917     322.637
  Degrees of freedom                               137         137
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.069
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.898       0.894
  Tucker-Lewis Index (TLI)                       0.886       0.881

  Robust Comparative Fit Index (CFI)                         0.902
  Robust Tucker-Lewis Index (TLI)                            0.890

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4456.504   -4456.504
  Scaling correction factor                                  1.024
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         52          52
  Akaike (AIC)                                9017.008    9017.008
  Bayesian (BIC)                              9173.907    9173.907
  Sample-size adjusted Bayesian (BIC)         9009.332    9009.332

Root Mean Square Error of Approximation:

  RMSEA                                          0.100       0.095
  90 Percent Confidence Interval          0.087  0.114       0.082  0.108
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.098
  90 Percent Confidence Interval                             0.084  0.112

Standardized Root Mean Square Residual:

  SRMR                                           0.095       0.095

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.167    0.262   12.087    0.000    3.167    0.970
    v2T1      (L2)    2.013    0.203    9.935    0.000    2.013    0.573
    v3T1      (L3)    2.058    0.194   10.599    0.000    2.058    0.811
    v4T1      (L4)    1.943    0.232    8.370    0.000    1.943    0.586
    v5T1      (L5)    0.931    0.144    6.473    0.000    0.931    0.516
    v6T1      (L6)    1.490    0.119   12.540    0.000    1.490    0.806
  Time2 =~                                                              
    v1T2      (L1)    2.697    0.229   11.777    0.000    2.834    0.963
    v2T2      (L2)    2.013    0.203    9.935    0.000    2.115    0.669
    v3T2      (L3)    2.058    0.194   10.599    0.000    2.163    0.825
    v4T2      (L4)    1.943    0.232    8.370    0.000    2.042    0.623
    v5T2      (L5)    0.931    0.144    6.473    0.000    0.978    0.407
    v6T2      (L6)    1.490    0.119   12.540    0.000    1.566    0.819
  Time3 =~                                                              
    v1T3      (L1)    2.697    0.229   11.777    0.000    2.552    0.955
    v2T3      (L2)    2.013    0.203    9.935    0.000    1.905    0.630
    v3T3      (L3)    2.058    0.194   10.599    0.000    1.948    0.796
    v4T3      (L4)    1.943    0.232    8.370    0.000    1.838    0.582
    v5T3      (L5)    0.931    0.144    6.473    0.000    0.881    0.495
    v6T3      (L6)    1.490    0.119   12.540    0.000    1.410    0.790

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.068    0.248   -0.272    0.785   -0.068   -0.108
   .v1T3   (C1T13)    0.197    0.231    0.854    0.393    0.197    0.315
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.261    0.259    1.010    0.312    0.261    0.417
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.678    0.628    5.858    0.000    3.678    0.543
   .v2T3   (C2T13)    2.130    0.767    2.775    0.006    2.130    0.315
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.047    0.558    3.670    0.000    2.047    0.371
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.914    0.285    3.204    0.001    0.914    0.416
   .v3T3   (C3T13)    0.946    0.265    3.568    0.000    0.946    0.430
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.102    0.298    3.700    0.000    1.102    0.501
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.732    0.819    5.775    0.000    4.732    0.687
   .v4T3   (C4T13)    3.908    1.000    3.910    0.000    3.908    0.567
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.585    0.822    5.582    0.000    4.585    0.697
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.760    0.861    3.205    0.001    2.760    0.813
   .v5T3   (C5T13)    1.339    0.423    3.168    0.002    1.339    0.561
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    2.514    0.707    3.556    0.000    2.514    0.741
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.673    0.139    4.851    0.000    0.673    0.560
   .v6T3   (C6T13)    0.549    0.164    3.357    0.001    0.549    0.458
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.741    0.176    4.204    0.000    0.741    0.617
  Time1 ~~                                                              
    Time2             0.825    0.074   11.091    0.000    0.785    0.785
    Time3             0.670    0.124    5.390    0.000    0.708    0.708
  Time2 ~~                                                              
    Time3             0.655    0.125    5.240    0.000    0.659    0.659

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.087    0.274   58.687    0.000   16.087    4.928
   .v2T1    (I2T1)    8.678    0.294   29.535    0.000    8.678    2.469
   .v3T1      (I3)   11.994    0.223   53.861    0.000   11.994    4.728
   .v4T1    (I4T1)   -3.021    0.267  -11.332    0.000   -3.021   -0.911
   .v5T1      (I5)   -1.459    0.150   -9.756    0.000   -1.459   -0.809
   .v6T1      (I6)   -2.810    0.159  -17.717    0.000   -2.810   -1.519
   .v1T2      (I1)   16.533    0.275   60.022    0.000   16.533    5.619
   .v2T2      (I2)    9.489    0.259   36.566    0.000    9.489    3.001
   .v3T2      (I3)   11.994    0.223   53.861    0.000   11.994    4.573
   .v4T2      (I4)   -3.665    0.284  -12.904    0.000   -3.665   -1.118
   .v5T2    (I5T2)   -1.935    0.233   -8.302    0.000   -1.935   -0.805
   .v6T2      (I6)   -2.810    0.159  -17.717    0.000   -2.810   -1.470
   .v1T3      (I1)   16.533    0.275   60.022    0.000   16.533    6.188
   .v2T3      (I2)    9.489    0.259   36.566    0.000    9.489    3.136
   .v3T3      (I3)   11.994    0.223   53.861    0.000   11.994    4.900
   .v4T3      (I4)   -3.665    0.284  -12.904    0.000   -3.665   -1.161
   .v5T3      (I5)   -1.459    0.150   -9.756    0.000   -1.459   -0.821
   .v6T3      (I6)   -2.810    0.159  -17.717    0.000   -2.810   -1.573
    Time1             0.000                               0.000    0.000
    Time2             0.254    0.075    3.382    0.001    0.242    0.242
    Time3             0.459    0.083    5.493    0.000    0.485    0.485

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.625    0.396    1.581    0.114    0.625    0.059
   .v2T1    (E2T1)    8.302    0.997    8.325    0.000    8.302    0.672
   .v3T1      (E3)    2.198    0.278    7.894    0.000    2.198    0.342
   .v4T1    (E4T1)    7.216    1.055    6.837    0.000    7.216    0.657
   .v5T1      (E5)    2.386    0.530    4.501    0.000    2.386    0.734
   .v6T1      (E6)    1.201    0.153    7.843    0.000    1.201    0.351
   .v1T2      (E1)    0.626    0.259    2.417    0.016    0.626    0.072
   .v2T2      (E2)    5.524    0.508   10.882    0.000    5.524    0.552
   .v3T2      (E3)    2.198    0.278    7.894    0.000    2.198    0.320
   .v4T2      (E4)    6.581    0.858    7.674    0.000    6.581    0.612
   .v5T2    (E5T2)    4.825    1.547    3.118    0.002    4.825    0.835
   .v6T2      (E6)    1.201    0.153    7.843    0.000    1.201    0.329
   .v1T3      (E1)    0.626    0.259    2.417    0.016    0.626    0.088
   .v2T3      (E2)    5.524    0.508   10.882    0.000    5.524    0.604
   .v3T3      (E3)    2.198    0.278    7.894    0.000    2.198    0.367
   .v4T3      (E4)    6.581    0.858    7.674    0.000    6.581    0.661
   .v5T3      (E5)    2.386    0.530    4.501    0.000    2.386    0.755
   .v6T3      (E6)    1.201    0.153    7.843    0.000    1.201    0.376
    Time1             1.000                               1.000    1.000
    Time2             1.104    0.169    6.551    0.000    1.000    1.000
    Time3             0.895    0.153    5.844    0.000    1.000    1.000

R-Square:
                   Estimate
    v1T1              0.941
    v2T1              0.328
    v3T1              0.658
    v4T1              0.343
    v5T1              0.266
    v6T1              0.649
    v1T2              0.928
    v2T2              0.448
    v3T2              0.680
    v4T2              0.388
    v5T2              0.165
    v6T2              0.671
    v1T3              0.912
    v2T3              0.396
    v3T3              0.633
    v4T3              0.339
    v5T3              0.245
    v6T3              0.624
anova(scalarEstimates4, residVarEstimates1)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                    Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)  
scalarEstimates4   129 9002.7 9183.7 314.56                                
residVarEstimates1 137 9017.0 9173.9 344.92     19.796       8    0.01114 *
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1
anova(configuralEstimates, residVarEstimates1)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                     Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)   
configuralEstimates 114 9010.6 9236.9 292.51                                 
residVarEstimates1  137 9017.0 9173.9 344.92     41.951      23   0.009199 **
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Does the partial residual variance model fit worse than the partial scalar model? Yes, −2∆LL(df=14) = 32.455, p <.01. A look at the modification indices reveals several items with large values. We will pick the residual variance from item6 at time1 to free.

#get modification indices for all parameters:
residVarMI1 = modificationindices(residVarEstimates1, free.remove = FALSE, maximum.number = 10000)
#restrict output to only residual variance parameters:
residVarMI1a = residVarMI1[which(residVarMI1$op == "~~" & residVarMI1$lhs == residVarMI1$rhs),]
residVarMI1a[order(-residVarMI1a$mi),]
     lhs op   rhs    mi mi.scaled    epc sepc.lv sepc.all sepc.nox
42  v6T1 ~~  v6T1 5.060     4.733  0.253   0.253    0.074    0.074
54  v6T3 ~~  v6T3 2.649     2.478 -0.185  -0.185   -0.058   -0.058
53  v5T3 ~~  v5T3 1.922     1.798  0.213   0.213    0.067    0.067
41  v5T1 ~~  v5T1 0.909     0.850 -0.101  -0.101   -0.031   -0.031
50  v2T3 ~~  v2T3 0.297     0.278 -0.363  -0.363   -0.040   -0.040
48  v6T2 ~~  v6T2 0.283     0.265 -0.050  -0.050   -0.014   -0.014
44  v2T2 ~~  v2T2 0.152     0.142  0.186   0.186    0.019    0.019
45  v3T2 ~~  v3T2 0.053     0.050 -0.050  -0.050   -0.007   -0.007
43  v1T2 ~~  v1T2 0.049     0.046  0.034   0.034    0.004    0.004
49  v1T3 ~~  v1T3 0.048     0.045 -0.034  -0.034   -0.005   -0.005
39  v3T1 ~~  v3T1 0.029     0.027  0.040   0.040    0.006    0.006
52  v4T3 ~~  v4T3 0.014     0.013 -0.057  -0.057   -0.006   -0.006
46  v4T2 ~~  v4T2 0.008     0.007  0.032   0.032    0.003    0.003
51  v3T3 ~~  v3T3 0.006     0.006  0.019   0.019    0.003    0.003
75 Time3 ~~ Time3 0.000     0.000  0.000   0.000    0.000    0.000
38  v2T1 ~~  v2T1 0.000     0.000  0.000   0.000    0.000    0.000
74 Time2 ~~ Time2 0.000     0.000  0.000   0.000    0.000    0.000
37  v1T1 ~~  v1T1 0.000     0.000  0.000   0.000    0.000    0.000
40  v4T1 ~~  v4T1 0.000     0.000  0.000   0.000    0.000    0.000
47  v5T2 ~~  v5T2 0.000     0.000  0.000   0.000    0.000    0.000
residVarSyntax2 = "
#===================================================================================================
#Factor loadings constrained across groups except non-invariant ones
Time1 =~ L1T1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2 + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3 + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all constrained across groups except non-invariant ones
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3*1; v4T1 ~ I4T1*1; v5T1 ~ I5*1; v6T1 ~ I6*1; 
v1T2 ~ I1*1;   v2T2 ~ I2*1;  v3T2 ~ I3*1; v4T2 ~ I4*1; v5T2 ~ I5T2*1; v6T2 ~ I6*1; 
v1T3 ~ I1*1;   v2T3 ~ I2*1;  v3T3 ~ I3*1; v4T3 ~ I4*1; v5T3 ~ I5*1; v6T3 ~ I6*1; 
#===================================================================================================
#Redidual variances all constrained in each group except non-invariant ones
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1*v1T2; v2T2 ~~ E2*v2T2;  v3T2 ~~ E3*v3T2; v4T2 ~~ E4*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6*v6T2;
v1T3 ~~ E1*v1T3; v2T3 ~~ E2*v2T3;  v3T3 ~~ E3*v3T3; v4T3 ~~ E4*v4T3; v5T3 ~~ E5*v5T3; v6T3 ~~ E6*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others
Time1 ~~ 1*Time1
Time2 ~~ Time2
Time3 ~~ Time3
#===================================================================================================
#Factor mean fixed to zero for identification first group, estimated in others
Time1 ~ 0
Time2 ~ 1
Time3 ~ 1
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Time2 + Time3
Time2 ~~ Time3 
"
residVarEstimates2 = lavaan(model = residVarSyntax2, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(residVarEstimates2, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 114 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              331.477     310.378
  Degrees of freedom                               136         136
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.068
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.904       0.900
  Tucker-Lewis Index (TLI)                       0.892       0.888

  Robust Comparative Fit Index (CFI)                         0.908
  Robust Tucker-Lewis Index (TLI)                            0.896

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4449.784   -4449.784
  Scaling correction factor                                  1.039
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         53          53
  Akaike (AIC)                                9005.568    9005.568
  Bayesian (BIC)                              9165.484    9165.484
  Sample-size adjusted Bayesian (BIC)         8997.744    8997.744

Root Mean Square Error of Approximation:

  RMSEA                                          0.098       0.092
  90 Percent Confidence Interval          0.084  0.111       0.079  0.105
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.095
  90 Percent Confidence Interval                             0.081  0.109

Standardized Root Mean Square Residual:

  SRMR                                           0.096       0.096

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.207    0.259   12.371    0.000    3.207    0.984
    v2T1      (L2)    1.968    0.198    9.931    0.000    1.968    0.559
    v3T1      (L3)    2.018    0.193   10.453    0.000    2.018    0.800
    v4T1      (L4)    1.925    0.226    8.525    0.000    1.925    0.584
    v5T1      (L5)    0.925    0.140    6.591    0.000    0.925    0.514
    v6T1      (L6)    1.494    0.119   12.526    0.000    1.494    0.759
  Time2 =~                                                              
    v1T2      (L1)    2.676    0.230   11.657    0.000    2.846    0.968
    v2T2      (L2)    1.968    0.198    9.931    0.000    2.093    0.663
    v3T2      (L3)    2.018    0.193   10.453    0.000    2.146    0.817
    v4T2      (L4)    1.925    0.226    8.525    0.000    2.047    0.621
    v5T2      (L5)    0.925    0.140    6.591    0.000    0.984    0.407
    v6T2      (L6)    1.494    0.119   12.526    0.000    1.589    0.852
  Time3 =~                                                              
    v1T3      (L1)    2.676    0.230   11.657    0.000    2.562    0.960
    v2T3      (L2)    1.968    0.198    9.931    0.000    1.884    0.624
    v3T3      (L3)    2.018    0.193   10.453    0.000    1.931    0.787
    v4T3      (L4)    1.925    0.226    8.525    0.000    1.842    0.581
    v5T3      (L5)    0.925    0.140    6.591    0.000    0.886    0.497
    v6T3      (L6)    1.494    0.119   12.526    0.000    1.430    0.826

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.148    0.244   -0.606    0.545   -0.148   -0.340
   .v1T3   (C1T13)    0.084    0.224    0.375    0.708    0.084    0.193
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.186    0.235    0.789    0.430    0.186    0.336
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.726    0.643    5.797    0.000    3.726    0.541
   .v2T3   (C2T13)    2.252    0.781    2.883    0.004    2.252    0.327
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.112    0.559    3.781    0.000    2.112    0.379
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.962    0.285    3.378    0.001    0.962    0.420
   .v3T3   (C3T13)    1.028    0.261    3.939    0.000    1.028    0.449
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.178    0.298    3.953    0.000    1.178    0.515
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.747    0.816    5.816    0.000    4.747    0.688
   .v4T3   (C4T13)    3.896    0.996    3.913    0.000    3.896    0.565
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.663    0.833    5.595    0.000    4.663    0.700
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.787    0.868    3.211    0.001    2.787    0.817
   .v5T3   (C5T13)    1.344    0.425    3.162    0.002    1.344    0.563
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    2.523    0.710    3.557    0.000    2.523    0.740
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.743    0.146    5.075    0.000    0.743    0.593
   .v6T3   (C6T13)    0.628    0.189    3.316    0.001    0.628    0.502
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.539    0.133    4.046    0.000    0.539    0.565
  Time1 ~~                                                              
    Time2             0.832    0.075   11.061    0.000    0.782    0.782
    Time3             0.673    0.125    5.395    0.000    0.703    0.703
  Time2 ~~                                                              
    Time3             0.674    0.125    5.395    0.000    0.662    0.662

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.084    0.275   58.554    0.000   16.084    4.934
   .v2T1    (I2T1)    8.679    0.294   29.565    0.000    8.679    2.467
   .v3T1      (I3)   11.998    0.222   53.971    0.000   11.998    4.758
   .v4T1    (I4T1)   -3.020    0.266  -11.335    0.000   -3.020   -0.917
   .v5T1      (I5)   -1.460    0.149   -9.769    0.000   -1.460   -0.811
   .v6T1      (I6)   -2.797    0.160  -17.520    0.000   -2.797   -1.421
   .v1T2      (I1)   16.529    0.276   59.867    0.000   16.529    5.619
   .v2T2      (I2)    9.497    0.258   36.784    0.000    9.497    3.010
   .v3T2      (I3)   11.998    0.222   53.971    0.000   11.998    4.570
   .v4T2      (I4)   -3.666    0.284  -12.899    0.000   -3.666   -1.113
   .v5T2    (I5T2)   -1.938    0.234   -8.294    0.000   -1.938   -0.802
   .v6T2      (I6)   -2.797    0.160  -17.520    0.000   -2.797   -1.500
   .v1T3      (I1)   16.529    0.276   59.867    0.000   16.529    6.197
   .v2T3      (I2)    9.497    0.258   36.784    0.000    9.497    3.144
   .v3T3      (I3)   11.998    0.222   53.971    0.000   11.998    4.891
   .v4T3      (I4)   -3.666    0.284  -12.899    0.000   -3.666   -1.156
   .v5T3      (I5)   -1.460    0.149   -9.769    0.000   -1.460   -0.820
   .v6T3      (I6)   -2.797    0.160  -17.520    0.000   -2.797   -1.615
    Time1             0.000                               0.000    0.000
    Time2             0.256    0.075    3.393    0.001    0.241    0.241
    Time3             0.464    0.085    5.461    0.000    0.484    0.484

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.341    0.372    0.916    0.360    0.341    0.032
   .v2T1    (E2T1)    8.509    1.009    8.434    0.000    8.509    0.687
   .v3T1      (E3)    2.288    0.277    8.276    0.000    2.288    0.360
   .v4T1    (E4T1)    7.140    1.044    6.838    0.000    7.140    0.658
   .v5T1      (E5)    2.389    0.531    4.496    0.000    2.389    0.736
   .v6T1    (E6T1)    1.641    0.238    6.902    0.000    1.641    0.424
   .v1T2      (E1)    0.553    0.238    2.327    0.020    0.553    0.064
   .v2T2      (E2)    5.575    0.503   11.093    0.000    5.575    0.560
   .v3T2      (E3)    2.288    0.277    8.276    0.000    2.288    0.332
   .v4T2      (E4)    6.665    0.866    7.697    0.000    6.665    0.614
   .v5T2    (E5T2)    4.870    1.560    3.123    0.002    4.870    0.834
   .v6T2      (E6)    0.956    0.136    7.003    0.000    0.956    0.275
   .v1T3      (E1)    0.553    0.238    2.327    0.020    0.553    0.078
   .v2T3      (E2)    5.575    0.503   11.093    0.000    5.575    0.611
   .v3T3      (E3)    2.288    0.277    8.276    0.000    2.288    0.380
   .v4T3      (E4)    6.665    0.866    7.697    0.000    6.665    0.663
   .v5T3      (E5)    2.389    0.531    4.496    0.000    2.389    0.753
   .v6T3      (E6)    0.956    0.136    7.003    0.000    0.956    0.319
    Time1             1.000                               1.000    1.000
    Time2             1.131    0.174    6.487    0.000    1.000    1.000
    Time3             0.916    0.151    6.050    0.000    1.000    1.000

R-Square:
                   Estimate
    v1T1              0.968
    v2T1              0.313
    v3T1              0.640
    v4T1              0.342
    v5T1              0.264
    v6T1              0.576
    v1T2              0.936
    v2T2              0.440
    v3T2              0.668
    v4T2              0.386
    v5T2              0.166
    v6T2              0.725
    v1T3              0.922
    v2T3              0.389
    v3T3              0.620
    v4T3              0.337
    v5T3              0.247
    v6T3              0.681
anova(scalarEstimates4, residVarEstimates2)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                    Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)
scalarEstimates4   129 9002.7 9183.7 314.56                              
residVarEstimates2 136 9005.6 9165.5 331.48     10.713       7     0.1516
anova(configuralEstimates, residVarEstimates2)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                     Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)  
configuralEstimates 114 9010.6 9236.9 292.51                                
residVarEstimates2  136 9005.6 9165.5 331.48     31.154      22    0.09302 .
---
Signif. codes:  0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1

Does the partial residual variance model fit worse than the partial scalar model? No, −2∆LL(df=13) = 21.898, p = .06. The residual covariances are not tested in this model as we allow/expect them to be non-zero due to the same items appearing across time. Up next is the structural model.

Factor Variance Invariance Model

factorVarCovSyntax1 = "
#===================================================================================================
#Factor loadings constrained across groups except non-invariant ones
Time1 =~ L1T1*v1T1 + L2*v2T1 + L3*v3T1 + L4*v4T1 + L5*v5T1 + L6*v6T1
Time2 =~ L1*v1T2 + L2*v2T2 + L3*v3T2 + L4*v4T2 + L5*v5T2 + L6*v6T2
Time3 =~ L1*v1T3 + L2*v2T3 + L3*v3T3 + L4*v4T3 + L5*v5T3 + L6*v6T3
#===================================================================================================
#Item intercepts all constrained across groups except non-invariant ones
v1T1 ~ I1T1*1; v2T1 ~ I2T1*1;  v3T1 ~ I3*1; v4T1 ~ I4T1*1; v5T1 ~ I5*1; v6T1 ~ I6*1; 
v1T2 ~ I1*1;   v2T2 ~ I2*1;  v3T2 ~ I3*1; v4T2 ~ I4*1; v5T2 ~ I5T2*1; v6T2 ~ I6*1; 
v1T3 ~ I1*1;   v2T3 ~ I2*1;  v3T3 ~ I3*1; v4T3 ~ I4*1; v5T3 ~ I5*1; v6T3 ~ I6*1; 
#===================================================================================================
#Redidual variances all constrained in each group except non-invariant ones
v1T1 ~~ E1T1*v1T1; v2T1 ~~ E2T1*v2T1;  v3T1 ~~ E3*v3T1; v4T1 ~~ E4T1*v4T1; v5T1 ~~ E5*v5T1; v6T1 ~~ E6T1*v6T1;
v1T2 ~~ E1*v1T2; v2T2 ~~ E2*v2T2;  v3T2 ~~ E3*v3T2; v4T2 ~~ E4*v4T2; v5T2 ~~ E5T2*v5T2; v6T2 ~~ E6*v6T2;
v1T3 ~~ E1*v1T3; v2T3 ~~ E2*v2T3;  v3T3 ~~ E3*v3T3; v4T3 ~~ E4*v4T3; v5T3 ~~ E5*v5T3; v6T3 ~~ E6*v6T3;
#===================================================================================================
#Residual covariances freely estimated in each group with labels
v1T1 ~~ C1T12*v1T2 + C1T13*v1T3; v1T2 ~~ C1T23*v1T3; 
v2T1 ~~ C2T12*v2T2 + C2T13*v2T3; v2T2 ~~ C2T23*v2T3; 
v3T1 ~~ C3T12*v3T2 + C3T13*v3T3; v3T2 ~~ C3T23*v3T3; 
v4T1 ~~ C4T12*v4T2 + C4T13*v4T3; v4T2 ~~ C4T23*v4T3; 
v5T1 ~~ C5T12*v5T2 + C5T13*v5T3; v5T2 ~~ C5T23*v5T3; 
v6T1 ~~ C6T12*v6T2 + C6T13*v6T3; v6T2 ~~ C6T23*v6T3; 
#===================================================================================================
#Factor variance fixed to 1 for identification in first group; estimated in others
Time1 ~~ 1*Time1
Time2 ~~ 1*Time2
Time3 ~~ 1*Time3
#===================================================================================================
#Factor mean fixed to zero for identification first group, estimated in others
Time1 ~ 0
Time2 ~ Fmean2*1
Time3 ~ Fmean3*1
#===================================================================================================
#Factor covariances all freely estimated
Time1 ~~ Fcov*Time2 + Fcov*Time3
Time2 ~~ Fcov*Time3 
#===================================================================================================
#Wald Tests for Factor Means:
DF1F2 := -Fmean2; DF1F3 := -Fmean3; DF2F3 := Fmean2-Fmean3
"
factorVarCovEstimates2 = lavaan(model = factorVarCovSyntax1, data = cafData, estimator = "MLR", mimic = "mplus")
lavaan WARNING: some cases are empty and will be ignored:
  16 58 64 75 76 133 153 156
summary(factorVarCovEstimates2, fit.measures = TRUE, rsquare = TRUE, standardized = TRUE)
lavaan (0.5-23.1097) converged normally after 110 iterations

                                                  Used       Total
  Number of observations                           151         159

  Number of missing patterns                         7

  Estimator                                         ML      Robust
  Minimum Function Test Statistic              338.526     311.664
  Degrees of freedom                               140         140
  P-value (Chi-square)                           0.000       0.000
  Scaling correction factor                                  1.086
    for the Yuan-Bentler correction (Mplus variant)

Model test baseline model:

  Minimum Function Test Statistic             2192.158    1896.786
  Degrees of freedom                               153         153
  P-value                                        0.000       0.000

User model versus baseline model:

  Comparative Fit Index (CFI)                    0.903       0.902
  Tucker-Lewis Index (TLI)                       0.894       0.892

  Robust Comparative Fit Index (CFI)                         0.907
  Robust Tucker-Lewis Index (TLI)                            0.899

Loglikelihood and Information Criteria:

  Loglikelihood user model (H0)              -4453.308   -4453.308
  Scaling correction factor                                  0.978
    for the MLR correction
  Loglikelihood unrestricted model (H1)      -4284.045   -4284.045
  Scaling correction factor                                  1.203
    for the MLR correction

  Number of free parameters                         49          49
  Akaike (AIC)                                9004.617    9004.617
  Bayesian (BIC)                              9152.463    9152.463
  Sample-size adjusted Bayesian (BIC)         8997.383    8997.383

Root Mean Square Error of Approximation:

  RMSEA                                          0.097       0.090
  90 Percent Confidence Interval          0.084  0.110       0.077  0.103
  P-value RMSEA <= 0.05                          0.000       0.000

  Robust RMSEA                                               0.094
  90 Percent Confidence Interval                             0.080  0.108

Standardized Root Mean Square Residual:

  SRMR                                           0.104       0.104

Parameter Estimates:

  Information                                 Observed
  Standard Errors                   Robust.huber.white

Latent Variables:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
  Time1 =~                                                              
    v1T1    (L1T1)    3.207    0.242   13.227    0.000    3.207    0.980
    v2T1      (L2)    2.001    0.170   11.787    0.000    2.001    0.567
    v3T1      (L3)    2.048    0.169   12.143    0.000    2.048    0.806
    v4T1      (L4)    1.935    0.215    8.994    0.000    1.935    0.587
    v5T1      (L5)    0.918    0.147    6.232    0.000    0.918    0.510
    v6T1      (L6)    1.519    0.108   14.072    0.000    1.519    0.766
  Time2 =~                                                              
    v1T2      (L1)    2.712    0.232   11.712    0.000    2.712    0.963
    v2T2      (L2)    2.001    0.170   11.787    0.000    2.001    0.648
    v3T2      (L3)    2.048    0.169   12.143    0.000    2.048    0.806
    v4T2      (L4)    1.935    0.215    8.994    0.000    1.935    0.599
    v5T2      (L5)    0.918    0.147    6.232    0.000    0.918    0.384
    v6T2      (L6)    1.519    0.108   14.072    0.000    1.519    0.843
  Time3 =~                                                              
    v1T3      (L1)    2.712    0.232   11.712    0.000    2.712    0.963
    v2T3      (L2)    2.001    0.170   11.787    0.000    2.001    0.648
    v3T3      (L3)    2.048    0.169   12.143    0.000    2.048    0.806
    v4T3      (L4)    1.935    0.215    8.994    0.000    1.935    0.599
    v5T3      (L5)    0.918    0.147    6.232    0.000    0.918    0.510
    v6T3      (L6)    1.519    0.108   14.072    0.000    1.519    0.843

Covariances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
 .v1T1 ~~                                                               
   .v1T2   (C1T12)   -0.085    0.236   -0.360    0.719   -0.085   -0.173
   .v1T3   (C1T13)    0.108    0.227    0.477    0.634    0.108    0.220
 .v1T2 ~~                                                               
   .v1T3    (C1T2)    0.160    0.247    0.649    0.517    0.160    0.277
 .v2T1 ~~                                                               
   .v2T2   (C2T12)    3.683    0.631    5.833    0.000    3.683    0.538
   .v2T3   (C2T13)    2.247    0.775    2.897    0.004    2.247    0.328
 .v2T2 ~~                                                               
   .v2T3    (C2T2)    2.129    0.558    3.813    0.000    2.129    0.384
 .v3T1 ~~                                                               
   .v3T2   (C3T12)    0.930    0.279    3.332    0.001    0.930    0.411
   .v3T3   (C3T13)    1.014    0.259    3.910    0.000    1.014    0.448
 .v3T2 ~~                                                               
   .v3T3    (C3T2)    1.174    0.297    3.952    0.000    1.174    0.519
 .v4T1 ~~                                                               
   .v4T2   (C4T12)    4.756    0.815    5.832    0.000    4.756    0.689
   .v4T3   (C4T13)    3.879    0.997    3.890    0.000    3.879    0.562
 .v4T2 ~~                                                               
   .v4T3    (C4T2)    4.633    0.835    5.552    0.000    4.633    0.694
 .v5T1 ~~                                                               
   .v5T2   (C5T12)    2.792    0.870    3.209    0.001    2.792    0.817
   .v5T3   (C5T13)    1.343    0.426    3.152    0.002    1.343    0.561
 .v5T2 ~~                                                               
   .v5T3    (C5T2)    2.519    0.711    3.544    0.000    2.519    0.737
 .v6T1 ~~                                                               
   .v6T2   (C6T12)    0.736    0.145    5.085    0.000    0.736    0.595
   .v6T3   (C6T13)    0.622    0.189    3.296    0.001    0.622    0.503
 .v6T2 ~~                                                               
   .v6T3    (C6T2)    0.538    0.132    4.072    0.000    0.538    0.573
  Time1 ~~                                                              
    Time2   (Fcov)    0.722    0.053   13.697    0.000    0.722    0.722
    Time3   (Fcov)    0.722    0.053   13.697    0.000    0.722    0.722
  Time2 ~~                                                              
    Time3   (Fcov)    0.722    0.053   13.697    0.000    0.722    0.722

Intercepts:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (I1T1)   16.097    0.271   59.488    0.000   16.097    4.920
   .v2T1    (I2T1)    8.686    0.292   29.752    0.000    8.686    2.462
   .v3T1      (I3)   12.003    0.220   54.487    0.000   12.003    4.724
   .v4T1    (I4T1)   -3.012    0.263  -11.451    0.000   -3.012   -0.913
   .v5T1      (I5)   -1.454    0.148   -9.792    0.000   -1.454   -0.808
   .v6T1      (I6)   -2.794    0.159  -17.598    0.000   -2.794   -1.408
   .v1T2      (I1)   16.537    0.274   60.252    0.000   16.537    5.871
   .v2T2      (I2)    9.501    0.256   37.133    0.000    9.501    3.075
   .v3T2      (I3)   12.003    0.220   54.487    0.000   12.003    4.724
   .v4T2      (I4)   -3.656    0.279  -13.089    0.000   -3.656   -1.133
   .v5T2    (I5T2)   -1.931    0.232   -8.319    0.000   -1.931   -0.807
   .v6T2      (I6)   -2.794    0.159  -17.598    0.000   -2.794   -1.551
   .v1T3      (I1)   16.537    0.274   60.252    0.000   16.537    5.871
   .v2T3      (I2)    9.501    0.256   37.133    0.000    9.501    3.075
   .v3T3      (I3)   12.003    0.220   54.487    0.000   12.003    4.724
   .v4T3      (I4)   -3.656    0.279  -13.089    0.000   -3.656   -1.133
   .v5T3      (I5)   -1.454    0.148   -9.792    0.000   -1.454   -0.808
   .v6T3      (I6)   -2.794    0.159  -17.598    0.000   -2.794   -1.551
    Time1             0.000                               0.000    0.000
    Time2   (Fmn2)    0.250    0.075    3.325    0.001    0.250    0.250
    Time3   (Fmn3)    0.470    0.088    5.319    0.000    0.470    0.470

Variances:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
   .v1T1    (E1T1)    0.418    0.360    1.161    0.246    0.418    0.039
   .v2T1    (E2T1)    8.443    1.001    8.435    0.000    8.443    0.678
   .v3T1      (E3)    2.262    0.273    8.274    0.000    2.262    0.350
   .v4T1    (E4T1)    7.139    1.042    6.852    0.000    7.139    0.656
   .v5T1      (E5)    2.395    0.532    4.506    0.000    2.395    0.740
   .v6T1    (E6T1)    1.629    0.239    6.818    0.000    1.629    0.414
   .v1T2      (E1)    0.579    0.235    2.463    0.014    0.579    0.073
   .v2T2      (E2)    5.542    0.493   11.243    0.000    5.542    0.581
   .v3T2      (E3)    2.262    0.273    8.274    0.000    2.262    0.350
   .v4T2      (E4)    6.676    0.870    7.677    0.000    6.676    0.641
   .v5T2    (E5T2)    4.882    1.563    3.124    0.002    4.882    0.853
   .v6T2      (E6)    0.940    0.131    7.163    0.000    0.940    0.289
   .v1T3      (E1)    0.579    0.235    2.463    0.014    0.579    0.073
   .v2T3      (E2)    5.542    0.493   11.243    0.000    5.542    0.581
   .v3T3      (E3)    2.262    0.273    8.274    0.000    2.262    0.350
   .v4T3      (E4)    6.676    0.870    7.677    0.000    6.676    0.641
   .v5T3      (E5)    2.395    0.532    4.506    0.000    2.395    0.740
   .v6T3      (E6)    0.940    0.131    7.163    0.000    0.940    0.289
    Time1             1.000                               1.000    1.000
    Time2             1.000                               1.000    1.000
    Time3             1.000                               1.000    1.000

R-Square:
                   Estimate
    v1T1              0.961
    v2T1              0.322
    v3T1              0.650
    v4T1              0.344
    v5T1              0.260
    v6T1              0.586
    v1T2              0.927
    v2T2              0.419
    v3T2              0.650
    v4T2              0.359
    v5T2              0.147
    v6T2              0.711
    v1T3              0.927
    v2T3              0.419
    v3T3              0.650
    v4T3              0.359
    v5T3              0.260
    v6T3              0.711

Defined Parameters:
                   Estimate  Std.Err  z-value  P(>|z|)   Std.lv  Std.all
    DF1F2            -0.250    0.075   -3.325    0.001   -0.250   -0.250
    DF1F3            -0.470    0.088   -5.319    0.000   -0.470   -0.470
    DF2F3            -0.220    0.077   -2.837    0.005   -0.220   -0.220
anova(residVarEstimates2, factorVarCovEstimates2)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                        Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)
residVarEstimates2     136 9005.6 9165.5 331.48                              
factorVarCovEstimates2 140 9004.6 9152.5 338.53     4.1332       4     0.3883
anova(configuralEstimates, factorVarCovEstimates2)
Scaled Chi Square Difference Test (method = "satorra.bentler.2001")

                        Df    AIC    BIC  Chisq Chisq diff Df diff Pr(>Chisq)
configuralEstimates    114 9010.6 9236.9 292.51                              
factorVarCovEstimates2 140 9004.6 9152.5 338.53     34.841      26     0.1151

Does constraining the factor variances and covariances cause the model to fit worse? No,-2∆LL = 4.1332 with 4 df, for a p-value of .3883. We will stop with the models here and use Wald tests to test the difference between factor means. From the defined parameters, we wee that all three differences in factor means are significant. The negative signs of the estimates tell us the factor is decreasing across time.

Example write-up for these analyses

The extent to which a confirmatory factor model measuring social functioning (with six observed indicators) exhibited measurement invariance and structural invariance over time (i.e., across three occasions taken at 6-month intervals) was examined using the lavaan package (Rosseel, 2012) in R (R Core Team, 2017). Robust maximum likelihood (MLR) estimation was used for all analyses; accordingly, nested model comparisons were conducted using the rescaled difference in the model −2LL values as a function of the difference in model degrees of freedom. A configural invariance model was initially specified in which three correlated factors (i.e., the factor at three occasions) were estimated simultaneously; all factor means were fixed to 0 and all factor variances were fixed to 1 for identification. Residual covariances between the same indicators across occasions were estimated as well. As shown in Table 1, although the configural invariance model had marginal fit, reasonable attempts to improve the fit were unsuccessful. Thus, the analysis proceeded by applying parameter constraints in successive models to examine potential decreases in fit resulting from measurement or structural non-invariance over the three occasions.

Equality of the unstandardized indicator factor loadings across occasions was then examined in a metric invariance model. The factor variance was fixed to 1 at time 1 but was freely estimated at times 2 and 3. All factor loadings were constrained equal across time; all intercepts and residual variances were still permitted to vary across time. Factor covariances and residual covariances were estimated as described previously. The metric invariance model fit significantly worse than the configural invariance model −2ΔLL(10) = 19.14, p = .04. The modification indices suggested that the loading of indicator 1 at time 1 was a source of misfit and should be freed. After doing so, the partial metric invariance model fit significantly better than the full metric invariance model, −2ΔLL(1) = 7.16, p < .001, and the partial metric invariance model did not fit worse than the configural invariance model−2ΔLL(9) = 8.98, p = .44. The fact that partial metric invariance (i.e., “weak invariance”) held indicates that the indicators were related to the latent factor equivalently across time, or more simply, that the same latent factor was being measured at each of occasion (with the exception of indicator 1, which was more related to the factor at time 1 than at times 2 or 3).

Equality of the unstandardized indicator intercepts across time was then examined in a scalar invariance model. The factor mean and variance were fixed to 0 and 1, respectively, at time 1 for identification, but the factor mean and variance were then estimated at times 2 and 3. All factor loadings and indicator intercepts were constrained equal across time (except for indicator 1 at time 1); all residual variances were still permitted to differ across time. Factor covariances and residual covariances were estimated as described previously. The scalar invariance model fit significantly worse than the partial metric invariance model, −2ΔLL(9) = 55.11, p < .01. The modification indices suggested that the intercept of indicator 2 at time 1 was the largest source of the misfit and should be freed. After doing so, although the partial scalar invariance model had significantly better fit than the full scalar invariance model, it still fit worse than the partial metric invariance model, −2ΔLL(8) = 39.321, p < 001. The modification indices suggested that the intercept of indicator 5 at time 2 was the largest remaining source of the misfit and should be freed. After doing so, although the new partial scalar invariance model (with the intercepts for indicators 1 and 2 at time 1 and 5 freed at time 2) fit significantly better than the previous partial scalar invariance model but it still fit marginally worse than the partial metric invariance model, −2ΔLL(7) = 21.99, p < .01. The modification indices suggested that the intercept of indicator 4 at time 1 was the largest remaining source of the misfit and should be freed. After doing so, the new partial scalar invariance model (with the intercepts for indicators 1, 2, and 4 at time 1 and 5 freed at time 2) fit significantly better than the previous partial scalar invariance model (without the intercept for indicator 2 freed at time 1), and it did not fit significantly worse than the partial metric invariance model, −2ΔLL(6) = 11.90, p = .06.

Equality of the unstandardized residual variances across time was then examined in a residual variance invariance model. As in the partial scalar invariance model, the factor mean and variance were fixed to 0 and 1, respectively, for identification at time 1, but the factor mean and variance were still estimated at times 2 and 3. All factor loadings (except for indicator 1 at time 1), item intercepts (except for indicators 1, 2, and 4 at time1 and 5 at time 2), and all residual variances (except for indicators 1, 2, and 4 at time1 and 5 at time 2) were constrained to be equal across groups. Factor covariances and residual covariances were estimated as described previously. The residual variance invariance model fit significantly worse than the last partial scalar invariance model, −2ΔLL(8) = 32.46, p < .01. The modification indices suggested that the residual variance of indicator 6 at time 1 was the largest remaining source of the misfit and should be freed. After doing so, the partial residual variance invariance model fit significantly better than the residual invariance model, −2ΔLL(1) = 21.898, p = 0.06.

After achieving partial measurement invariance as was just described, structural invariance of factor variances and covariances was then tested by constraining the factor variances to one and the factor covariances to be equal across all time points, resulting in a nonsignificant decrease in fit relative to the last partial residual invariance model, −2ΔLL(4) = 4.13, p = .39. The difference between factor means at each time point was tested using Wald tests using the previous model with constrained factor variances and covariances. The difference between the mean at time 1 and time 2 was -.250 (p < .01), the difference between the factor means at times 1 and 3 was -.47, (p < .01), and the difference between the factor means at times 2 and 3 was -.22, (p < .01).

In conclusion, these analyses showed that partial measurement invariance was obtained over time-that is, the relationships of the indicators to the latent factor of social functioning were equivalent at times 2 and 3, although primarily not equivalent at time 1, as previous described. These analyses also showed that partial structural invariance was obtained over time, such that the same amount of individual differences variance in social functioning was observed with equal covariance over time across occasions (i.e., compound symmetry of the latent factor), although the amount of social functioning on average increased significantly over time. Model parameters from the final model are given in Table 2.

(Table 1 would have likelihood ratio tests; Table 2 would have unstandardized and standardized estimates and their SEs)

LS0tCnRpdGxlOiAiRVBTWSA5MDYvQ0xEUCA5NDggRXhhbXBsZSA3QjogTG9uZ2l0dWRpbmFsIEludmFyaWFuY2Ugd2l0aCBDRkEiCm91dHB1dDoKICBodG1sX25vdGVib29rOiBkZWZhdWx0CiAgaHRtbF9kb2N1bWVudDogZGVmYXVsdAotLS0KCmBgYHtyIHNldHVwLCBpbmNsdWRlPVRSVUV9CmlmICghcmVxdWlyZShsYXZhYW4pKSBpbnN0YWxsLnBhY2thZ2VzKCJsYXZhYW4iKQpsaWJyYXJ5KGxhdmFhbikKYGBgCgojI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woKIz09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojUmVzaWR1YWwgY292YXJpYW5jZXMgZnJlZWx5IGVzdGltYXRlZCBpbiBlYWNoIGdyb3VwIHdpdGggbGFiZWxzCnYxVDEgfn4gQzFUMTIqdjFUMiArIEMxVDEzKnYxVDM7IHYxVDIgfn4gQzFUMjMqdjFUMzsgCnYyVDEgfn4gQzJUMTIqdjJUMiArIEMyVDEzKnYyVDM7IHYyVDIgfn4gQzJUMjMqdjJUMzsgCnYzVDEgfn4gQzNUMTIqdjNUMiArIEMzVDEzKnYzVDM7IHYzVDIgfn4gQzNUMjMqdjNUMzsgCnY0VDEgfn4gQzRUMTIqdjRUMiArIEM0VDEzKnY0VDM7IHY0VDIgfn4gQzRUMjMqdjRUMzsgCnY1VDEgfn4gQzVUMTIqdjVUMiArIEM1VDEzKnY1VDM7IHY1VDIgfn4gQzVUMjMqdjVUMzsgCnY2VDEgfn4gQzZUMTIqdjZUMiArIEM2VDEzKnY2VDM7IHY2VDIgfn4gQzZUMjMqdjZUMzsgCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgdmFyaWFuY2UgZml4ZWQgdG8gMSBmb3IgaWRlbnRpZmljYXRpb24gaW4gZWFjaCBncm91cApUaW1lMSB+fiAxKlRpbWUxClRpbWUyIH5+IDEqVGltZTIKVGltZTMgfn4gMSpUaW1lMwoKIz09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojRmFjdG9yIG1lYW4gZml4ZWQgdG8gemVybyBmb3IgaWRlbnRpZmljYXRpb24gaW4gZWFjaCBncm91cApUaW1lMSB+IDAKVGltZTIgfiAwClRpbWUzIH4gMAoKIz09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojRmFjdG9yIGNvdmFyaWFuY2VzIGFsbCBmcmVlbHkgZXN0aW1hdGVkClRpbWUxIH5+IFRpbWUyICsgVGltZTMKVGltZTIgfn4gVGltZTMgCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiIKCmNvbmZpZ3VyYWxFc3RpbWF0ZXMgPSBsYXZhYW4obW9kZWwgPSBjb25maWd1cmFsU3ludGF4LCBkYXRhID0gY2FmRGF0YSwgZXN0aW1hdG9yID0gIk1MUiIsIG1pbWljID0gIm1wbHVzIikKc3VtbWFyeShjb25maWd1cmFsRXN0aW1hdGVzLCBmaXQubWVhc3VyZXMgPSBUUlVFLCByc3F1YXJlID0gVFJVRSwgc3RhbmRhcmRpemVkID0gVFJVRSkKYGBgCgpBbHRob3VnaCB0aGUgZml0IGlzIG5vdCBncmVhdCwgYXR0ZW1wdHMgdG8gaW1wcm92ZSBpdCBsb2dpY2FsbHkgd2VyZSB1bnN1Y2Nlc3NmdWwsIHNvIHdlIHByb2NlZWQgZnJvbSBoZXJlIHdpdGggdGhpcyBhcyB0aGUgY29uZmlndXJhbCBpbnZhcmlhbmNlIG1vZGVsLiBUaGlzIGZvcmVzaGFkb3dzIHRoZSBtZXRyaWMgaW52YXJpYW5jZSBzZWN0aW9uIHVwIG5leHQuCgojIyMgMi4gTWV0cmljIEludmFyaWFuY2UgTW9kZWxzIChBTEwgbG9hZGluZ3MgaGVsZCBlcXVhbCBhY3Jvc3MgdGltZSAtIGlkZW50aWZpZWQgbW9kZWwgdXNpbmcgVGltZTEgRmFjdG9yIFZhcmlhbmN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zVDEyKnYzVDIgKyBDM1QxMyp2M1QzOyB2M1QyIH5+IEMzVDIzKnYzVDM7IAp2NFQxIH5+IEM0VDEyKnY0VDIgKyBDNFQxMyp2NFQzOyB2NFQyIH5+IEM0VDIzKnY0VDM7IAp2NVQxIH5+IEM1VDEyKnY1VDIgKyBDNVQxMyp2NVQzOyB2NVQyIH5+IEM1VDIzKnY1VDM7IAp2NlQxIH5+IEM2VDEyKnY2VDIgKyBDNlQxMyp2NlQzOyB2NlQyIH5+IEM2VDIzKnY2VDM7ICAKCiM9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KI0ZhY3RvciB2YXJpYW5jZSBmaXhlZCB0byAxIGZvciBpZGVudGlmaWNhdGlvbiBpbiBmaXJzdCBncm91cDsgZXN0aW1hdGVkIGluIG90aGVycyAqKioqKgpUaW1lMSB+fiAxKlRpbWUxClRpbWUyIH5+IFRpbWUyClRpbWUzIH5+IFRpbWUzCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgbWVhbiBmaXhlZCB0byB6ZXJvIGZvciBpZGVudGlmaWNhdGlvbiBpbiBlYWNoIGdyb3VwClRpbWUxIH4gMApUaW1lMiB+IDAKVGltZTMgfiAwCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgY292YXJpYW5jZXMgYWxsIGZyZWVseSBlc3RpbWF0ZWQKVGltZTEgfn4gVGltZTIgKyBUaW1lMwpUaW1lMiB+fiBUaW1lMyAKCiM9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT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BzZWxlY3QgdGhlIGxvYWRpbmcgb2YgaXRlbTEgYXQgdGltZTEgdG8gZnJlZSBhbmQgY29udGludWUuIEluIHByYWN0aWNlLCB3ZSB3b3VsZCBmcmVlIG9uZSBvZiB0aGVzZSB0d28gcGFyYW1ldGVycywgbm90IG5lY2Vzc2FyaWx5IHRoZSBvbmUgd2UgaGF2ZSBjaG9zZW4uCgoKYGBge3IgbWV0cmljMiwgaW5jbHVkZT1UUlVFfQptZXRyaWNTeW50YXgyID0gIgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgbG9hZGluZ3MgY29uc3RyYWluZWQgYWNyb3NzIGdyb3VwcyBleGNlcHQgbm9uLWludmFyaWFudCBvbmVzICoqKioqClRpbWUxID1+IEwxVDEqdjFUMSArIEwyKnYyVDEgKyBMMyp2M1QxICsgTDQqdjRUMSArIEw1KnY1VDEgKyBMNip2NlQxClRpbWUyID1+IEwxKnYxVDIgICArIEwyKnYyVDIgKyBMMyp2M1QyICsgTDQqdjRUMiArIEw1KnY1VDIgKyBMNip2NlQyClRpbWUzID1+IEwxKnYxVDMgICArIEwyKnYyVDMgKyBMMyp2M1QzICsgTDQqdjRUMyArIEw1KnY1VDMgKyBMNip2NlQzCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNJdGVtIGludGVyY2VwdHMgYWxsIGZyZWVseSBlc3RpbWF0ZWQgaW4gZWFjaCBncm91cCB3aXRoIGxhYmVscwp2MVQxIH4gSTFUMSoxOyB2MlQxIH4gSTJUMSoxOyAgdjNUMSB+IEkzVDEqMTsgdjRUMSB+IEk0VDEqMTsgdjVUMSB+IEk1VDEqMTsgdjZUMSB+IEk2VDEqMTsgCnYxVDIgfiBJ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yKnYzVDIgKyBDM1QxMyp2M1QzOyB2M1QyIH5+IEMzVDIzKnYzVDM7IAp2NFQxIH5+IEM0VDEyKnY0VDIgKyBDNFQxMyp2NFQzOyB2NFQyIH5+IEM0VDIzKnY0VDM7IAp2NVQxIH5+IEM1VDEyKnY1VDIgKyBDNVQxMyp2NVQzOyB2NVQyIH5+IEM1VDIzKnY1VDM7IAp2NlQxIH5+IEM2VDEyKnY2VDIgKyBDNlQxMyp2NlQzOyB2NlQyIH5+IEM2VDIzKnY2VDM7IAoKIz09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojRmFjdG9yIHZhcmlhbmNlIGZpeGVkIHRvIDEgZm9yIGlkZW50aWZpY2F0aW9uIGluIGZpcnN0IGdyb3VwOyBlc3RpbWF0ZWQgaW4gb3RoZXJzClRpbWUxIH5+IDEqVGltZTEKVGltZTIgfn4gVGltZTIKVGltZTMgfn4gVGltZTMKCiM9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KI0ZhY3RvciBtZWFuIGZpeGVkIHRvIHplcm8gZm9yIGlkZW50aWZpY2F0aW9uIGZpcnN0IGdyb3VwLCBlc3RpbWF0ZWQgaW4gb3RoZXJzICoqKioKVGltZTEgfiAwClRpbWUyIH4gMQpUaW1lMyB+IDEKCiM9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KI0ZhY3RvciBjb3ZhcmlhbmNlcyBhbGwgZnJlZWx5IGVzdGltYXRlZApUaW1lMSB+fiBUaW1lMiArIFRpbWUzClRpbWUyIH5+IFRpbWUzIAoKIgoKc2NhbGFyRXN0aW1hdGVz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DMlQyMyp2MlQzOyAKdjNUMSB+fiBDM1QxMip2M1QyICsgQzNUMTMqdjNUMzsgdjNUMiB+fiBDM1QyMyp2M1QzOyAKdjRUMSB+fiBDNFQxMip2NFQyICsgQzRUMTMqdjRUMzsgdjRUMiB+fiBDNFQyMyp2NFQzOyAKdjVUMSB+fiBDNVQxMip2NVQyICsgQzVUMTMqdjVUMzsgdjVUMiB+fiBDNVQyMyp2NVQzOyAKdjZUMSB+fiBDNlQxMip2NlQyICsgQzZUMTMqdjZUMzsgdjZUMiB+fiBDNlQyMyp2NlQzOyAKCiM9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KI0ZhY3RvciB2YXJpYW5jZSBmaXhlZCB0byAxIGZvciBpZGVudGlmaWNhdGlvbiBpbiBmaXJzdCBncm91cDsgZXN0aW1hdGVkIGluIG90aGVycwpUaW1lMSB+fiAxKlRpbWUxClRpbWUyIH5+IFRpbWUyClRpbWUzIH5+IFRpbWUzCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgbWVhbiBmaXhlZCB0byB6ZXJvIGZvciBpZGVudGlmaWNhdGlvbiBmaXJzdCBncm91cCwgZXN0aW1hdGVkIGluIG90aGVycyAqKioqClRpbWUxIH4gMApUaW1lMiB+IDEKVGltZTMgfiAxCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgY292YXJpYW5jZXMgYWxsIGZyZWVseSBlc3RpbWF0ZWQKVGltZTEgfn4gVGltZTIgKyBUaW1lMwpUaW1lMiB+fiBUaW1lMyAKCiIKCnNjYWxh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QyMyp2MlQzOyAKdjNUMSB+fiBDM1QxMip2M1QyICsgQzNUMTMqdjNUMzsgdjNUMiB+fiBDM1QyMyp2M1QzOyAKdjRUMSB+fiBDNFQxMip2NFQyICsgQzRUMTMqdjRUMzsgdjRUMiB+fiBDNFQyMyp2NFQzOyAKdjVUMSB+fiBDNVQxMip2NVQyICsgQzVUMTMqdjVUMzsgdjVUMiB+fiBDNVQyMyp2NVQzOyAKdjZUMSB+fiBDNlQxMip2NlQyICsgQzZUMTMqdjZUMzsgdjZUMiB+fiBDNlQyMyp2NlQzOyAKCiM9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KI0ZhY3RvciB2YXJpYW5jZSBmaXhlZCB0byAxIGZvciBpZGVudGlmaWNhdGlvbiBpbiBmaXJzdCBncm91cDsgZXN0aW1hdGVkIGluIG90aGVycwpUaW1lMSB+fiAxKlRpbWUxClRpbWUyIH5+IFRpbWUyClRpbWUzIH5+IFRpbWUzCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgbWVhbiBmaXhlZCB0byB6ZXJvIGZvciBpZGVudGlmaWNhdGlvbiBmaXJzdCBncm91cCwgZXN0aW1hdGVkIGluIG90aGVycyAqKioqClRpbWUxIH4gMApUaW1lMiB+IDEKVGltZTMgfiAxCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgY292YXJpYW5jZXMgYWxsIGZyZWVseSBlc3RpbWF0ZWQKVGltZTEgfn4gVGltZTIgKyBUaW1lMwpUaW1lMiB+fiBUaW1lMyAKCiIKCnNjYWxhckVz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zsgCnYzVDEgfn4gQzNUMTIqdjNUMiArIEMzVDEzKnYzVDM7IHYzVDIgfn4gQzNUMjMqdjNUMzsgCnY0VDEgfn4gQzRUMTIqdjRUMiArIEM0VDEzKnY0VDM7IHY0VDIgfn4gQzRUMjMqdjRUMzsgCnY1VDEgfn4gQzVUMTIqdjVUMiArIEM1VDEzKnY1VDM7IHY1VDIgfn4gQzVUMjMqdjVUMzsgCnY2VDEgfn4gQzZUMTIqdjZUMiArIEM2VDEzKnY2VDM7IHY2VDIgfn4gQzZUMjMqdjZUMzsgCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgdmFyaWFuY2UgZml4ZWQgdG8gMSBmb3IgaWRlbnRpZmljYXRpb24gaW4gZmlyc3QgZ3JvdXA7IGVzdGltYXRlZCBpbiBvdGhlcnMKVGltZTEgfn4gMSpUaW1lMQpUaW1lMiB+fiBUaW1lMgpUaW1lMyB+fiBUaW1lMwoKIz09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojRmFjdG9yIG1lYW4gZml4ZWQgdG8gemVybyBmb3IgaWRlbnRpZmljYXRpb24gZmlyc3QgZ3JvdXAsIGVzdGltYXRlZCBpbiBvdGhlcnMgKioqKgpUaW1lMSB+IDAKVGltZTIgfiAxClRpbWUzIH4gMQoKIz09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojRmFjdG9yIGNvdmFyaWFuY2VzIGFsbCBmcmVlbHkgZXN0aW1hdGVkClRpbWUxIH5+IFRpbWUyICsgVGltZTMKVGltZTIgfn4gVGltZTMgCgoiCgpzY2FsYX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W5jZSBmaXhlZCB0byAxIGZvciBpZGVudGlmaWNhdGlvbiBpbiBmaXJzdCBncm91cDsgZXN0aW1hdGVkIGluIG90aGVycwpUaW1lMSB+fiAxKlRpbWUxClRpbWUyIH5+IFRpbWUyClRpbWUzIH5+IFRpbWUzCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgbWVhbiBmaXhlZCB0byB6ZXJvIGZvciBpZGVudGlmaWNhdGlvbiBmaXJzdCBncm91cCwgZXN0aW1hdGVkIGluIG90aGVycwpUaW1lMSB+IDAKVGltZTIgfiAxClRpbWUzIH4gMQoKIz09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojRmFjdG9yIGNvdmFyaWFuY2VzIGFsbCBmcmVlbHkgZXN0aW1hdGVkClRpbWUxIH5+IFRpbWUyICsgVGltZTMKVGltZTIgfn4gVGltZTMgCgoiCgpyZXNpZFZhckVzdGltYXRlczEgPSBsYXZhYW4obW9kZWwgPSByZXNpZFZhclN5bnRheDEsIGRhdGEgPSBjYWZEYXRhLCBlc3RpbWF0b3IgPSAiTUxSIiwgbWltaWMgPSAibXBsdXMiKQpzdW1tYXJ5KHJlc2lkVmFyRXN0aW1hdGVzMSwgZml0Lm1lYXN1cmVzID0gVFJVRSwgcnNxdWFyZSA9IFRSVUUsIHN0YW5kYXJkaXplZCA9IFRSVUUpCmFub3ZhKHNjYWxhckVzdGltYXRlczQsIHJlc2lkVmFyRXN0aW1hdGVzMSkKYW5vdmEoY29uZmlndXJhbEVzdGltYXRlcywgcmVzaWRWYXJFc3RpbWF0ZXMxKQpgYGAKCkRvZXMgdGhlIHBhcnRpYWwgcmVzaWR1YWwgdmFyaWFuY2UgbW9kZWwgZml0IHdvcn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PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojRmFjdG9yIHZhcmlhbmNlIGZpeGVkIHRvIDEgZm9yIGlkZW50aWZpY2F0aW9uIGluIGZpcnN0IGdyb3VwOyBlc3RpbWF0ZWQgaW4gb3RoZXJzClRpbWUxIH5+IDEqVGltZTEKVGltZTIgfn4gVGltZTIKVGltZTMgfn4gVGltZTMKCiM9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KI0ZhY3RvciBtZWFuIGZpeGVkIHRvIHplcm8gZm9yIGlkZW50aWZpY2F0aW9uIGZpcnN0IGdyb3VwLCBlc3RpbWF0ZWQgaW4gb3RoZXJzClRpbWUxIH4gMApUaW1lMiB+IDEKVGltZTMgfiAxCgojPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09CiNGYWN0b3IgY292YXJpYW5jZXMgYWxsIGZyZWVseSBlc3RpbWF0ZWQKVGltZTEgfn4gVGltZTIgKyBUaW1lMwpUaW1lMiB+fiBUaW1lMyAKCiIKCnJlc2lkVmFyRXN0aW1hdGVzMiA9IGxhdmFhbihtb2RlbCA9IHJlc2lkVmFyU3ludGF4MiwgZGF0YSA9IGNhZkRhdGEsIGVzdGltYXRvciA9ICJNTFIiLCBtaW1pYyA9ICJtcGx1cyIpCnN1bW1hcnkocmVzaWRWYXJFc3RpbWF0ZXMyLCBmaXQubWVhc3VyZXMgPSBUUlVFLCByc3F1YXJlID0gVFJVRSwgc3RhbmRhcmRpemVkID0gVFJVRSkKYW5vdmEoc2NhbGFyRXN0aW1hdGVzNCwgcmVzaWRWYXJFc3RpbWF0ZXMyKQphbm92YShjb25maWd1cmFsRXN0aW1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T09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KI0ZhY3RvciBtZWFuIGZpeGVkIHRvIHplcm8gZm9yIGlkZW50aWZpY2F0aW9uIGZpcnN0IGdyb3VwLCBlc3RpbWF0ZWQgaW4gb3RoZXJzClRpbWUxIH4gMApUaW1lMiB+IEZtZWFuMioxClRpbWUzIH4gRm1lYW4zKjEKCiM9PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT0KI0ZhY3RvciBjb3ZhcmlhbmNlcyBhbGwgZnJlZWx5IGVzdGltYXRlZApUaW1lMSB+fiBGY292KlRpbWUyICsgRmNvdipUaW1lMwpUaW1lMiB+fiBGY292KlRpbWUzIAoKIz09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PQojV2FsZCBUZXN0cyBmb3IgRmFjdG9yIE1lYW5zOgpERjFGMiA6PSAtRm1lYW4yOyBERjFGMyA6PSAtRm1lYW4zOyBERjJGMyA6PSBGbWVhbjItRm1lYW4zCgoiCgpmYWN0b3JWYXJDb3ZFc3RpbWF0ZXMyID0gbGF2YWFuKG1vZGVsID0gZmFjdG9yVmFyQ292U3ludGF4MSwgZGF0YSA9IGNhZkRhdGEsIGVzdGltYXRvciA9ICJNTFIiLCBtaW1pYyA9ICJtcGx1cyIpCnN1bW1hcnkoZmFjdG9yVmFyQ292RXN0aW1hdGVzMiwgZml0Lm1lYXN1cmVzID0gVFJVRSwgcnNxdWFyZSA9IFRSVUUsIHN0YW5kYXJkaXplZCA9IFRSVUUpCmFub3ZhKHJlc2lkVmFyRXN0aW1hdGVzMiwgZmFjdG9yVmFyQ292RXN0aW1hdGVzMikKYW5vdmEoY29uZmlndXJhbEVzdGltYXRlcywgZmFjd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