Visit team populism for various other publications, data, resources and more.
Data & R markdown file also available at https://osf.io/g8d53
packages <- c("lavaan" , "semPlot", "semTools", "psych", "tidyverse", "reshape2", "knitr")
for(i in packages){
if(!require(i, character.only = T)) install.packages(i, dependencies=T)
library(i, character.only = T)
}
## Loading required package: lavaan
## This is lavaan 0.6-5.1457
## lavaan is BETA software! Please report any bugs.
## Loading required package: semPlot
## Registered S3 methods overwritten by 'huge':
## method from
## plot.sim BDgraph
## print.sim BDgraph
## Loading required package: semTools
##
## ###############################################################################
## This is semTools 0.5-1
## All users of R (or SEM) are invited to submit functions or ideas for functions.
## ###############################################################################
## Loading required package: psych
##
## Attaching package: 'psych'
## The following object is masked from 'package:semTools':
##
## skew
## The following object is masked from 'package:lavaan':
##
## cor2cov
## Loading required package: tidyverse
## -- Attaching packages ---------------------------------------------------------------------------------------------------------------- tidyverse 1.2.1 --
## v ggplot2 3.2.1 v purrr 0.3.2
## v tibble 2.1.3 v dplyr 0.8.3
## v tidyr 0.8.3 v stringr 1.4.0
## v readr 1.3.1 v forcats 0.4.0
## -- Conflicts ------------------------------------------------------------------------------------------------------------------- tidyverse_conflicts() --
## x ggplot2::%+%() masks psych::%+%()
## x ggplot2::alpha() masks psych::alpha()
## x readr::clipboard() masks semTools::clipboard()
## x dplyr::filter() masks stats::filter()
## x dplyr::lag() masks stats::lag()
## Loading required package: reshape2
##
## Attaching package: 'reshape2'
## The following object is masked from 'package:tidyr':
##
## smiths
## Loading required package: knitr
options(knitr.kable.NA = '')
load("dataUS.RData")
load("dataDE1.RData")
load("dataDE2.RData")
popexp1 = EXPTRT
convert the experimental treatment into factor
US$EXPTRT <- factor(US$EXPTRT, levels = c(0,1), labels = c("Control","Treatment"))
US_model_PE <- '
pop =~ ant1 + ant2 + ant3 + ant5 + pop2 + pop3 + pop4 # populist attitudes
ase =~ anes617 + anes616 + anes615 # active support in elections
ase ~ pop # regression
'
US_PE_r_fit <- sem (US_model_PE, US, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances",
"regressions"),
group.partial=c("means")) # restricted model
US_PE_f_fit <- sem (US_model_PE, US, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances"),
group.partial=c("regressions", "means")) # free model
anova(US_PE_r_fit, US_PE_f_fit)
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## US_PE_f_fit 96 15231 15383 194.47
## US_PE_r_fit 97 15231 15378 196.59 1.8669 1 0.1718
cf <- compareFit(US_PE_r_fit, US_PE_f_fit, nested=T)
summary(cf)
## ################### Nested Model Comparison #########################
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## US_PE_f_fit 96 15231 15383 194.47
## US_PE_r_fit 97 15231 15378 196.59 1.8669 1 0.1718
##
## ####################### Model Fit Indices ###########################
## chisq.scaled df.scaled pvalue.scaled cfi.robust tli.robust
## US_PE_f_fit 147.006† 96 .001 .970† .972†
## US_PE_r_fit 148.826 97 .001 .970 .972
## aic bic rmsea.robust srmr
## US_PE_f_fit 15230.596† 15382.603 .047† .089†
## US_PE_r_fit 15230.716 15378.252† .047 .090
##
## ################## Differences in Fit Indices #######################
## df.scaled cfi.robust tli.robust aic bic
## US_PE_r_fit - US_PE_r_fit 1 0 0 0.12 -4.351
## rmsea.robust srmr
## US_PE_r_fit - US_PE_r_fit 0 0.001
summary(US_PE_r_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 56 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 64
## Number of equality constraints 31
## Row rank of the constraints matrix 31
##
## Number of observations per group
## Control 331
## Treatment 315
## Number of missing patterns per group
## Control 109
## Treatment 110
##
## Model Fit Test Statistic 196.587 148.826
## Degrees of freedom 97 97
## P-value (Chi-square) 0.000 0.001
## Scaling correction factor 1.321
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## Control 98.281 74.404
## Treatment 98.306 74.423
##
## Model test baseline model:
##
## Minimum Function Test Statistic 2389.856 1552.707
## Degrees of freedom 90 90
## P-value 0.000 0.000
## Scaling correction factor 1.539
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.957 0.965
## Tucker-Lewis Index (TLI) 0.960 0.967
##
## Robust Comparative Fit Index (CFI) 0.970
## Robust Tucker-Lewis Index (TLI) 0.972
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -7582.358 -7582.358
## Scaling correction factor 0.844
## for the MLR correction
## Loglikelihood unrestricted model (H1) -7484.064 -7484.064
## Scaling correction factor 1.401
## for the MLR correction
##
## Number of free parameters 33 33
## Akaike (AIC) 15230.716 15230.716
## Bayesian (BIC) 15378.252 15378.252
## Sample-size adjusted Bayesian (BIC) 15273.478 15273.478
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.056 0.041
## 90 Percent Confidence Interval 0.045 0.068 0.029 0.052
## P-value RMSEA <= 0.05 0.171 0.917
##
## Robust RMSEA 0.047
## 90 Percent Confidence Interval 0.031 0.061
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.090 0.090
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 1.000 1.187 0.844
## ant2 (.p2.) 0.948 0.059 16.116 0.000 1.125 0.796
## ant3 (.p3.) 0.868 0.078 11.145 0.000 1.030 0.717
## ant5 (.p4.) 0.959 0.077 12.515 0.000 1.139 0.689
## pop2 (.p5.) 0.530 0.071 7.476 0.000 0.630 0.500
## pop3 (.p6.) 0.852 0.079 10.818 0.000 1.011 0.626
## pop4 (.p7.) 0.593 0.086 6.857 0.000 0.703 0.459
## ase =~
## anes617 1.000 1.563 0.935
## anes616 (.p9.) 1.041 0.038 27.245 0.000 1.626 0.939
## anes615 (.10.) 0.812 0.046 17.705 0.000 1.269 0.751
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## ase ~
## pop (.11.) -0.315 0.071 -4.451 0.000 -0.239 -0.239
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.24.) 5.581 0.083 67.213 0.000 5.581 3.969
## .ant2 (.25.) 5.552 0.082 67.317 0.000 5.552 3.928
## .ant3 (.26.) 5.242 0.083 63.171 0.000 5.242 3.650
## .ant5 (.27.) 4.563 0.092 49.372 0.000 4.563 2.761
## .pop2 (.28.) 5.725 0.068 83.980 0.000 5.725 4.546
## .pop3 (.29.) 5.184 0.090 57.682 0.000 5.184 3.210
## .pop4 (.30.) 5.071 0.081 62.344 0.000 5.071 3.310
## .anes617 (.31.) 2.027 0.089 22.869 0.000 2.027 1.213
## .anes616 (.32.) 2.131 0.094 22.631 0.000 2.131 1.230
## .anes615 (.33.) 2.087 0.084 24.897 0.000 2.087 1.236
## pop 0.000 0.000 0.000
## .ase 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.12.) 0.569 0.115 4.953 0.000 0.569 0.288
## .ant2 (.13.) 0.731 0.118 6.216 0.000 0.731 0.366
## .ant3 (.14.) 1.002 0.132 7.596 0.000 1.002 0.486
## .ant5 (.15.) 1.433 0.157 9.120 0.000 1.433 0.525
## .pop2 (.16.) 1.190 0.141 8.425 0.000 1.190 0.750
## .pop3 (.17.) 1.586 0.208 7.612 0.000 1.586 0.608
## .pop4 (.18.) 1.853 0.167 11.088 0.000 1.853 0.789
## .anes617 (.19.) 0.352 0.083 4.258 0.000 0.352 0.126
## .anes616 (.20.) 0.356 0.103 3.448 0.001 0.356 0.119
## .anes615 (.21.) 1.244 0.137 9.052 0.000 1.244 0.436
## pop (.22.) 1.409 0.154 9.142 0.000 1.000 1.000
## .ase (.23.) 2.302 0.200 11.503 0.000 0.943 0.943
##
## R-Square:
## Estimate
## ant1 0.712
## ant2 0.634
## ant3 0.514
## ant5 0.475
## pop2 0.250
## pop3 0.392
## pop4 0.211
## anes617 0.874
## anes616 0.881
## anes615 0.564
## ase 0.057
##
##
## Group 2 [Treatment]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 1.000 1.187 0.844
## ant2 (.p2.) 0.948 0.059 16.116 0.000 1.125 0.796
## ant3 (.p3.) 0.868 0.078 11.145 0.000 1.030 0.717
## ant5 (.p4.) 0.959 0.077 12.515 0.000 1.139 0.689
## pop2 (.p5.) 0.530 0.071 7.476 0.000 0.630 0.500
## pop3 (.p6.) 0.852 0.079 10.818 0.000 1.011 0.626
## pop4 (.p7.) 0.593 0.086 6.857 0.000 0.703 0.459
## ase =~
## anes617 1.000 1.563 0.935
## anes616 (.p9.) 1.041 0.038 27.245 0.000 1.626 0.939
## anes615 (.10.) 0.812 0.046 17.705 0.000 1.269 0.751
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## ase ~
## pop (.11.) -0.315 0.071 -4.451 0.000 -0.239 -0.239
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.24.) 5.581 0.083 67.213 0.000 5.581 3.969
## .ant2 (.25.) 5.552 0.082 67.317 0.000 5.552 3.928
## .ant3 (.26.) 5.242 0.083 63.171 0.000 5.242 3.650
## .ant5 (.27.) 4.563 0.092 49.372 0.000 4.563 2.761
## .pop2 (.28.) 5.725 0.068 83.980 0.000 5.725 4.546
## .pop3 (.29.) 5.184 0.090 57.682 0.000 5.184 3.210
## .pop4 (.30.) 5.071 0.081 62.344 0.000 5.071 3.310
## .anes617 (.31.) 2.027 0.089 22.869 0.000 2.027 1.213
## .anes616 (.32.) 2.131 0.094 22.631 0.000 2.131 1.230
## .anes615 (.33.) 2.087 0.084 24.897 0.000 2.087 1.236
## pop -0.014 0.105 -0.130 0.897 -0.012 -0.012
## .ase 0.045 0.124 0.361 0.718 0.029 0.029
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.12.) 0.569 0.115 4.953 0.000 0.569 0.288
## .ant2 (.13.) 0.731 0.118 6.216 0.000 0.731 0.366
## .ant3 (.14.) 1.002 0.132 7.596 0.000 1.002 0.486
## .ant5 (.15.) 1.433 0.157 9.120 0.000 1.433 0.525
## .pop2 (.16.) 1.190 0.141 8.425 0.000 1.190 0.750
## .pop3 (.17.) 1.586 0.208 7.612 0.000 1.586 0.608
## .pop4 (.18.) 1.853 0.167 11.088 0.000 1.853 0.789
## .anes617 (.19.) 0.352 0.083 4.258 0.000 0.352 0.126
## .anes616 (.20.) 0.356 0.103 3.448 0.001 0.356 0.119
## .anes615 (.21.) 1.244 0.137 9.052 0.000 1.244 0.436
## pop (.22.) 1.409 0.154 9.142 0.000 1.000 1.000
## .ase (.23.) 2.302 0.200 11.503 0.000 0.943 0.943
##
## R-Square:
## Estimate
## ant1 0.712
## ant2 0.634
## ant3 0.514
## ant5 0.475
## pop2 0.250
## pop3 0.392
## pop4 0.211
## anes617 0.874
## anes616 0.881
## anes615 0.564
## ase 0.057
summary(US_PE_f_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 58 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 64
## Number of equality constraints 30
## Row rank of the constraints matrix 30
##
## Number of observations per group
## Control 331
## Treatment 315
## Number of missing patterns per group
## Control 109
## Treatment 110
##
## Model Fit Test Statistic 194.467 147.006
## Degrees of freedom 96 96
## P-value (Chi-square) 0.000 0.001
## Scaling correction factor 1.323
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## Control 97.300 73.554
## Treatment 97.167 73.453
##
## Model test baseline model:
##
## Minimum Function Test Statistic 2389.856 1552.707
## Degrees of freedom 90 90
## P-value 0.000 0.000
## Scaling correction factor 1.539
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.957 0.965
## Tucker-Lewis Index (TLI) 0.960 0.967
##
## Robust Comparative Fit Index (CFI) 0.970
## Robust Tucker-Lewis Index (TLI) 0.972
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -7581.298 -7581.298
## Scaling correction factor 0.862
## for the MLR correction
## Loglikelihood unrestricted model (H1) -7484.064 -7484.064
## Scaling correction factor 1.401
## for the MLR correction
##
## Number of free parameters 34 34
## Akaike (AIC) 15230.596 15230.596
## Bayesian (BIC) 15382.603 15382.603
## Sample-size adjusted Bayesian (BIC) 15274.654 15274.654
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.056 0.041
## 90 Percent Confidence Interval 0.045 0.068 0.029 0.052
## P-value RMSEA <= 0.05 0.173 0.918
##
## Robust RMSEA 0.047
## 90 Percent Confidence Interval 0.031 0.061
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.089 0.089
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 1.000 1.187 0.844
## ant2 (.p2.) 0.949 0.059 16.060 0.000 1.126 0.797
## ant3 (.p3.) 0.868 0.078 11.171 0.000 1.030 0.717
## ant5 (.p4.) 0.960 0.076 12.567 0.000 1.139 0.689
## pop2 (.p5.) 0.532 0.071 7.511 0.000 0.631 0.501
## pop3 (.p6.) 0.849 0.078 10.833 0.000 1.008 0.624
## pop4 (.p7.) 0.594 0.086 6.888 0.000 0.705 0.460
## ase =~
## anes617 1.000 1.540 0.934
## anes616 (.p9.) 1.040 0.038 27.086 0.000 1.601 0.937
## anes615 (.10.) 0.811 0.046 17.675 0.000 1.250 0.746
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## ase ~
## pop -0.238 0.088 -2.690 0.007 -0.183 -0.183
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.24.) 5.580 0.083 67.234 0.000 5.580 3.970
## .ant2 (.25.) 5.552 0.082 67.299 0.000 5.552 3.927
## .ant3 (.26.) 5.243 0.083 63.171 0.000 5.243 3.651
## .ant5 (.27.) 4.562 0.092 49.349 0.000 4.562 2.761
## .pop2 (.28.) 5.725 0.068 83.960 0.000 5.725 4.545
## .pop3 (.29.) 5.184 0.090 57.737 0.000 5.184 3.211
## .pop4 (.30.) 5.072 0.081 62.316 0.000 5.072 3.310
## .anes617 (.31.) 2.027 0.089 22.861 0.000 2.027 1.229
## .anes616 (.32.) 2.131 0.094 22.638 0.000 2.131 1.246
## .anes615 (.33.) 2.087 0.084 24.898 0.000 2.087 1.246
## pop 0.000 0.000 0.000
## .ase 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.12.) 0.568 0.115 4.935 0.000 0.568 0.287
## .ant2 (.13.) 0.730 0.118 6.197 0.000 0.730 0.365
## .ant3 (.14.) 1.002 0.131 7.622 0.000 1.002 0.486
## .ant5 (.15.) 1.435 0.157 9.152 0.000 1.435 0.525
## .pop2 (.16.) 1.188 0.141 8.419 0.000 1.188 0.749
## .pop3 (.17.) 1.592 0.208 7.636 0.000 1.592 0.610
## .pop4 (.18.) 1.851 0.166 11.131 0.000 1.851 0.789
## .anes617 (.19.) 0.349 0.083 4.206 0.000 0.349 0.128
## .anes616 (.20.) 0.359 0.103 3.477 0.001 0.359 0.123
## .anes615 (.21.) 1.245 0.137 9.058 0.000 1.245 0.443
## pop (.22.) 1.408 0.154 9.164 0.000 1.000 1.000
## .ase (.23.) 2.293 0.199 11.503 0.000 0.966 0.966
##
## R-Square:
## Estimate
## ant1 0.713
## ant2 0.635
## ant3 0.514
## ant5 0.475
## pop2 0.251
## pop3 0.390
## pop4 0.211
## anes617 0.872
## anes616 0.877
## anes615 0.557
## ase 0.034
##
##
## Group 2 [Treatment]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 1.000 1.187 0.844
## ant2 (.p2.) 0.949 0.059 16.060 0.000 1.126 0.797
## ant3 (.p3.) 0.868 0.078 11.171 0.000 1.030 0.717
## ant5 (.p4.) 0.960 0.076 12.567 0.000 1.139 0.689
## pop2 (.p5.) 0.532 0.071 7.511 0.000 0.631 0.501
## pop3 (.p6.) 0.849 0.078 10.833 0.000 1.008 0.624
## pop4 (.p7.) 0.594 0.086 6.888 0.000 0.705 0.460
## ase =~
## anes617 1.000 1.590 0.937
## anes616 (.p9.) 1.040 0.038 27.086 0.000 1.653 0.940
## anes615 (.10.) 0.811 0.046 17.675 0.000 1.290 0.756
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## ase ~
## pop -0.409 0.101 -4.034 0.000 -0.305 -0.305
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.24.) 5.580 0.083 67.234 0.000 5.580 3.970
## .ant2 (.25.) 5.552 0.082 67.299 0.000 5.552 3.927
## .ant3 (.26.) 5.243 0.083 63.171 0.000 5.243 3.651
## .ant5 (.27.) 4.562 0.092 49.349 0.000 4.562 2.761
## .pop2 (.28.) 5.725 0.068 83.960 0.000 5.725 4.545
## .pop3 (.29.) 5.184 0.090 57.737 0.000 5.184 3.211
## .pop4 (.30.) 5.072 0.081 62.316 0.000 5.072 3.310
## .anes617 (.31.) 2.027 0.089 22.861 0.000 2.027 1.195
## .anes616 (.32.) 2.131 0.094 22.638 0.000 2.131 1.212
## .anes615 (.33.) 2.087 0.084 24.898 0.000 2.087 1.224
## pop -0.014 0.105 -0.132 0.895 -0.012 -0.012
## .ase 0.044 0.125 0.348 0.728 0.027 0.027
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.12.) 0.568 0.115 4.935 0.000 0.568 0.287
## .ant2 (.13.) 0.730 0.118 6.197 0.000 0.730 0.365
## .ant3 (.14.) 1.002 0.131 7.622 0.000 1.002 0.486
## .ant5 (.15.) 1.435 0.157 9.152 0.000 1.435 0.525
## .pop2 (.16.) 1.188 0.141 8.419 0.000 1.188 0.749
## .pop3 (.17.) 1.592 0.208 7.636 0.000 1.592 0.610
## .pop4 (.18.) 1.851 0.166 11.131 0.000 1.851 0.789
## .anes617 (.19.) 0.349 0.083 4.206 0.000 0.349 0.121
## .anes616 (.20.) 0.359 0.103 3.477 0.001 0.359 0.116
## .anes615 (.21.) 1.245 0.137 9.058 0.000 1.245 0.428
## pop (.22.) 1.408 0.154 9.164 0.000 1.000 1.000
## .ase (.23.) 2.293 0.199 11.503 0.000 0.907 0.907
##
## R-Square:
## Estimate
## ant1 0.713
## ant2 0.635
## ant3 0.514
## ant5 0.475
## pop2 0.251
## pop3 0.390
## pop4 0.211
## anes617 0.879
## anes616 0.884
## anes615 0.572
## ase 0.093
par(mfrow=c(2,2))
semPaths(US_PE_r_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
semPaths(US_PE_f_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
dev.off()
## null device
## 1
US_model_NE <- '
pop =~ ant1 + ant2 + ant3 + ant5 + pop2 + pop3 + pop4 # populist attitudes
rpa =~ radact1 + radact2 + radact3 + radact5 + radact6 # legitimate radical political action
rpa ~ pop # regression
'
US_NE_r_fit <- sem (US_model_NE, US, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances",
"regressions"),
group.partial=c("means"))
US_NE_f_fit <- sem (US_model_NE, US, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances"),
group.partial=c("regressions", "means"))
anova(US_NE_r_fit, US_NE_f_fit)
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## US_NE_f_fit 140 16048 16227 301.80
## US_NE_r_fit 141 16050 16225 306.01 4.2679 1 0.03884 *
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
cf <- compareFit(US_NE_r_fit, US_NE_f_fit, nested=T)
summary(cf)
## ################### Nested Model Comparison #########################
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## US_NE_f_fit 140 16048 16227 301.80
## US_NE_r_fit 141 16050 16225 306.01 4.2679 1 0.03884 *
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## ####################### Model Fit Indices ###########################
## chisq.scaled df.scaled pvalue.scaled cfi.robust tli.robust
## US_NE_f_fit 256.871† 140 .000 .916† .921†
## US_NE_r_fit 260.751 141 .000 .914 .919
## aic bic rmsea.robust srmr
## US_NE_f_fit 16048.103† 16226.935 .055† .095†
## US_NE_r_fit 16050.314 16224.675† .056 .101
##
## ################## Differences in Fit Indices #######################
## df.scaled cfi.robust tli.robust aic bic
## US_NE_r_fit - US_NE_r_fit 1 -0.002 -0.001 2.211 -2.26
## rmsea.robust srmr
## US_NE_r_fit - US_NE_r_fit 0 0.006
summary(US_NE_r_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 56 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 76
## Number of equality constraints 37
## Row rank of the constraints matrix 37
##
## Number of observations per group
## Control 331
## Treatment 315
## Number of missing patterns per group
## Control 308
## Treatment 304
##
## Model Fit Test Statistic 306.013 260.751
## Degrees of freedom 141 141
## P-value (Chi-square) 0.000 0.000
## Scaling correction factor 1.174
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## Control 169.178 144.155
## Treatment 136.835 116.596
##
## Model test baseline model:
##
## Minimum Function Test Statistic 1803.589 1371.892
## Degrees of freedom 132 132
## P-value 0.000 0.000
## Scaling correction factor 1.315
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.901 0.903
## Tucker-Lewis Index (TLI) 0.908 0.910
##
## Robust Comparative Fit Index (CFI) 0.914
## Robust Tucker-Lewis Index (TLI) 0.919
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -7986.157 -7986.157
## Scaling correction factor 0.763
## for the MLR correction
## Loglikelihood unrestricted model (H1) -7833.150 -7833.150
## Scaling correction factor 1.242
## for the MLR correction
##
## Number of free parameters 39 39
## Akaike (AIC) 16050.314 16050.314
## Bayesian (BIC) 16224.675 16224.675
## Sample-size adjusted Bayesian (BIC) 16100.852 16100.852
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.060 0.051
## 90 Percent Confidence Interval 0.051 0.069 0.042 0.060
## P-value RMSEA <= 0.05 0.035 0.396
##
## Robust RMSEA 0.056
## 90 Percent Confidence Interval 0.045 0.066
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.101 0.101
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 1.000 1.201 0.853
## ant2 (.p2.) 0.935 0.058 16.236 0.000 1.123 0.796
## ant3 (.p3.) 0.846 0.077 11.039 0.000 1.016 0.707
## ant5 (.p4.) 0.943 0.076 12.338 0.000 1.132 0.684
## pop2 (.p5.) 0.521 0.070 7.501 0.000 0.626 0.497
## pop3 (.p6.) 0.847 0.077 11.035 0.000 1.017 0.631
## pop4 (.p7.) 0.579 0.086 6.763 0.000 0.695 0.454
## rpa =~
## radact1 1.000 1.062 0.720
## radact2 (.p9.) 1.293 0.138 9.340 0.000 1.372 0.809
## radact3 (.10.) 1.324 0.120 11.001 0.000 1.406 0.861
## radact5 (.11.) 1.211 0.125 9.697 0.000 1.285 0.828
## radact6 (.12.) 1.065 0.100 10.600 0.000 1.130 0.624
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## rpa ~
## pop (.13.) -0.061 0.048 -1.278 0.201 -0.069 -0.069
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.28.) 5.579 0.083 67.073 0.000 5.579 3.966
## .ant2 (.29.) 5.554 0.082 67.414 0.000 5.554 3.934
## .ant3 (.30.) 5.243 0.083 63.372 0.000 5.243 3.652
## .ant5 (.31.) 4.564 0.092 49.353 0.000 4.564 2.759
## .pop2 (.32.) 5.725 0.068 83.955 0.000 5.725 4.547
## .pop3 (.33.) 5.187 0.090 57.690 0.000 5.187 3.215
## .pop4 (.34.) 5.069 0.081 62.400 0.000 5.069 3.310
## .radact1 (.35.) 1.855 0.081 22.871 0.000 1.855 1.259
## .radact2 (.36.) 2.399 0.095 25.127 0.000 2.399 1.414
## .radact3 (.37.) 2.231 0.092 24.141 0.000 2.231 1.367
## .radact5 (.38.) 2.200 0.087 25.198 0.000 2.200 1.418
## .radact6 (.39.) 2.886 0.098 29.456 0.000 2.886 1.593
## pop 0.000 0.000 0.000
## .rpa 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.14.) 0.537 0.112 4.809 0.000 0.537 0.272
## .ant2 (.15.) 0.732 0.117 6.246 0.000 0.732 0.367
## .ant3 (.16.) 1.030 0.136 7.592 0.000 1.030 0.500
## .ant5 (.17.) 1.455 0.160 9.067 0.000 1.455 0.532
## .pop2 (.18.) 1.193 0.142 8.413 0.000 1.193 0.753
## .pop3 (.19.) 1.568 0.207 7.564 0.000 1.568 0.602
## .pop4 (.20.) 1.863 0.169 11.012 0.000 1.863 0.794
## .radact1 (.21.) 1.046 0.152 6.892 0.000 1.046 0.481
## .radact2 (.22.) 0.995 0.228 4.369 0.000 0.995 0.346
## .radact3 (.23.) 0.689 0.171 4.030 0.000 0.689 0.258
## .radact5 (.24.) 0.756 0.179 4.234 0.000 0.756 0.314
## .radact6 (.25.) 2.007 0.215 9.345 0.000 2.007 0.611
## pop (.26.) 1.442 0.153 9.427 0.000 1.000 1.000
## .rpa (.27.) 1.122 0.191 5.878 0.000 0.995 0.995
##
## R-Square:
## Estimate
## ant1 0.728
## ant2 0.633
## ant3 0.500
## ant5 0.468
## pop2 0.247
## pop3 0.398
## pop4 0.206
## radact1 0.519
## radact2 0.654
## radact3 0.742
## radact5 0.686
## radact6 0.389
## rpa 0.005
##
##
## Group 2 [Treatment]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 1.000 1.201 0.853
## ant2 (.p2.) 0.935 0.058 16.236 0.000 1.123 0.796
## ant3 (.p3.) 0.846 0.077 11.039 0.000 1.016 0.707
## ant5 (.p4.) 0.943 0.076 12.338 0.000 1.132 0.684
## pop2 (.p5.) 0.521 0.070 7.501 0.000 0.626 0.497
## pop3 (.p6.) 0.847 0.077 11.035 0.000 1.017 0.631
## pop4 (.p7.) 0.579 0.086 6.763 0.000 0.695 0.454
## rpa =~
## radact1 1.000 1.062 0.720
## radact2 (.p9.) 1.293 0.138 9.340 0.000 1.372 0.809
## radact3 (.10.) 1.324 0.120 11.001 0.000 1.406 0.861
## radact5 (.11.) 1.211 0.125 9.697 0.000 1.285 0.828
## radact6 (.12.) 1.065 0.100 10.600 0.000 1.130 0.624
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## rpa ~
## pop (.13.) -0.061 0.048 -1.278 0.201 -0.069 -0.069
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.28.) 5.579 0.083 67.073 0.000 5.579 3.966
## .ant2 (.29.) 5.554 0.082 67.414 0.000 5.554 3.934
## .ant3 (.30.) 5.243 0.083 63.372 0.000 5.243 3.652
## .ant5 (.31.) 4.564 0.092 49.353 0.000 4.564 2.759
## .pop2 (.32.) 5.725 0.068 83.955 0.000 5.725 4.547
## .pop3 (.33.) 5.187 0.090 57.690 0.000 5.187 3.215
## .pop4 (.34.) 5.069 0.081 62.400 0.000 5.069 3.310
## .radact1 (.35.) 1.855 0.081 22.871 0.000 1.855 1.259
## .radact2 (.36.) 2.399 0.095 25.127 0.000 2.399 1.414
## .radact3 (.37.) 2.231 0.092 24.141 0.000 2.231 1.367
## .radact5 (.38.) 2.200 0.087 25.198 0.000 2.200 1.418
## .radact6 (.39.) 2.886 0.098 29.456 0.000 2.886 1.593
## pop -0.014 0.107 -0.133 0.894 -0.012 -0.012
## .rpa 0.141 0.092 1.534 0.125 0.133 0.133
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.14.) 0.537 0.112 4.809 0.000 0.537 0.272
## .ant2 (.15.) 0.732 0.117 6.246 0.000 0.732 0.367
## .ant3 (.16.) 1.030 0.136 7.592 0.000 1.030 0.500
## .ant5 (.17.) 1.455 0.160 9.067 0.000 1.455 0.532
## .pop2 (.18.) 1.193 0.142 8.413 0.000 1.193 0.753
## .pop3 (.19.) 1.568 0.207 7.564 0.000 1.568 0.602
## .pop4 (.20.) 1.863 0.169 11.012 0.000 1.863 0.794
## .radact1 (.21.) 1.046 0.152 6.892 0.000 1.046 0.481
## .radact2 (.22.) 0.995 0.228 4.369 0.000 0.995 0.346
## .radact3 (.23.) 0.689 0.171 4.030 0.000 0.689 0.258
## .radact5 (.24.) 0.756 0.179 4.234 0.000 0.756 0.314
## .radact6 (.25.) 2.007 0.215 9.345 0.000 2.007 0.611
## pop (.26.) 1.442 0.153 9.427 0.000 1.000 1.000
## .rpa (.27.) 1.122 0.191 5.878 0.000 0.995 0.995
##
## R-Square:
## Estimate
## ant1 0.728
## ant2 0.633
## ant3 0.500
## ant5 0.468
## pop2 0.247
## pop3 0.398
## pop4 0.206
## radact1 0.519
## radact2 0.654
## radact3 0.742
## radact5 0.686
## radact6 0.389
## rpa 0.005
summary(US_NE_f_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 64 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 76
## Number of equality constraints 36
## Row rank of the constraints matrix 36
##
## Number of observations per group
## Control 331
## Treatment 315
## Number of missing patterns per group
## Control 308
## Treatment 304
##
## Model Fit Test Statistic 301.802 256.871
## Degrees of freedom 140 140
## P-value (Chi-square) 0.000 0.000
## Scaling correction factor 1.175
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## Control 167.716 142.746
## Treatment 134.087 114.124
##
## Model test baseline model:
##
## Minimum Function Test Statistic 1803.589 1371.892
## Degrees of freedom 132 132
## P-value 0.000 0.000
## Scaling correction factor 1.315
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.903 0.906
## Tucker-Lewis Index (TLI) 0.909 0.911
##
## Robust Comparative Fit Index (CFI) 0.916
## Robust Tucker-Lewis Index (TLI) 0.921
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -7984.052 -7984.052
## Scaling correction factor 0.776
## for the MLR correction
## Loglikelihood unrestricted model (H1) -7833.150 -7833.150
## Scaling correction factor 1.242
## for the MLR correction
##
## Number of free parameters 40 40
## Akaike (AIC) 16048.103 16048.103
## Bayesian (BIC) 16226.935 16226.935
## Sample-size adjusted Bayesian (BIC) 16099.937 16099.937
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.060 0.051
## 90 Percent Confidence Interval 0.051 0.069 0.042 0.060
## P-value RMSEA <= 0.05 0.041 0.428
##
## Robust RMSEA 0.055
## 90 Percent Confidence Interval 0.044 0.066
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.095 0.095
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 1.000 1.201 0.854
## ant2 (.p2.) 0.933 0.058 16.182 0.000 1.121 0.794
## ant3 (.p3.) 0.843 0.076 11.034 0.000 1.012 0.705
## ant5 (.p4.) 0.942 0.077 12.294 0.000 1.132 0.684
## pop2 (.p5.) 0.524 0.069 7.535 0.000 0.629 0.499
## pop3 (.p6.) 0.849 0.076 11.114 0.000 1.020 0.632
## pop4 (.p7.) 0.581 0.086 6.785 0.000 0.698 0.456
## rpa =~
## radact1 1.000 1.055 0.718
## radact2 (.p9.) 1.292 0.138 9.382 0.000 1.363 0.807
## radact3 (.10.) 1.321 0.119 11.060 0.000 1.393 0.859
## radact5 (.11.) 1.211 0.125 9.715 0.000 1.277 0.827
## radact6 (.12.) 1.065 0.100 10.624 0.000 1.123 0.621
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## rpa ~
## pop 0.019 0.052 0.362 0.718 0.021 0.021
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.28.) 5.579 0.083 67.015 0.000 5.579 3.966
## .ant2 (.29.) 5.553 0.082 67.475 0.000 5.553 3.934
## .ant3 (.30.) 5.242 0.083 63.386 0.000 5.242 3.652
## .ant5 (.31.) 4.563 0.093 49.302 0.000 4.563 2.758
## .pop2 (.32.) 5.724 0.068 83.874 0.000 5.724 4.546
## .pop3 (.33.) 5.188 0.090 57.700 0.000 5.188 3.217
## .pop4 (.34.) 5.071 0.081 62.412 0.000 5.071 3.310
## .radact1 (.35.) 1.855 0.081 22.865 0.000 1.855 1.263
## .radact2 (.36.) 2.397 0.095 25.123 0.000 2.397 1.420
## .radact3 (.37.) 2.229 0.092 24.148 0.000 2.229 1.373
## .radact5 (.38.) 2.200 0.087 25.189 0.000 2.200 1.424
## .radact6 (.39.) 2.887 0.098 29.450 0.000 2.887 1.596
## pop 0.000 0.000 0.000
## .rpa 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.14.) 0.535 0.111 4.822 0.000 0.535 0.271
## .ant2 (.15.) 0.737 0.118 6.251 0.000 0.737 0.370
## .ant3 (.16.) 1.036 0.136 7.631 0.000 1.036 0.503
## .ant5 (.17.) 1.458 0.161 9.045 0.000 1.458 0.532
## .pop2 (.18.) 1.190 0.142 8.377 0.000 1.190 0.751
## .pop3 (.19.) 1.561 0.207 7.543 0.000 1.561 0.600
## .pop4 (.20.) 1.859 0.170 10.968 0.000 1.859 0.792
## .radact1 (.21.) 1.044 0.151 6.905 0.000 1.044 0.484
## .radact2 (.22.) 0.993 0.227 4.376 0.000 0.993 0.348
## .radact3 (.23.) 0.693 0.169 4.106 0.000 0.693 0.263
## .radact5 (.24.) 0.754 0.179 4.224 0.000 0.754 0.316
## .radact6 (.25.) 2.008 0.215 9.351 0.000 2.008 0.614
## pop (.26.) 1.443 0.153 9.430 0.000 1.000 1.000
## .rpa (.27.) 1.112 0.189 5.890 0.000 1.000 1.000
##
## R-Square:
## Estimate
## ant1 0.729
## ant2 0.630
## ant3 0.497
## ant5 0.468
## pop2 0.249
## pop3 0.400
## pop4 0.208
## radact1 0.516
## radact2 0.652
## radact3 0.737
## radact5 0.684
## radact6 0.386
## rpa 0.000
##
##
## Group 2 [Treatment]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 1.000 1.201 0.854
## ant2 (.p2.) 0.933 0.058 16.182 0.000 1.121 0.794
## ant3 (.p3.) 0.843 0.076 11.034 0.000 1.012 0.705
## ant5 (.p4.) 0.942 0.077 12.294 0.000 1.132 0.684
## pop2 (.p5.) 0.524 0.069 7.535 0.000 0.629 0.499
## pop3 (.p6.) 0.849 0.076 11.114 0.000 1.020 0.632
## pop4 (.p7.) 0.581 0.086 6.785 0.000 0.698 0.456
## rpa =~
## radact1 1.000 1.072 0.724
## radact2 (.p9.) 1.292 0.138 9.382 0.000 1.385 0.812
## radact3 (.10.) 1.321 0.119 11.060 0.000 1.416 0.862
## radact5 (.11.) 1.211 0.125 9.715 0.000 1.298 0.831
## radact6 (.12.) 1.065 0.100 10.624 0.000 1.141 0.627
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## rpa ~
## pop -0.160 0.079 -2.022 0.043 -0.179 -0.179
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.28.) 5.579 0.083 67.015 0.000 5.579 3.966
## .ant2 (.29.) 5.553 0.082 67.475 0.000 5.553 3.934
## .ant3 (.30.) 5.242 0.083 63.386 0.000 5.242 3.652
## .ant5 (.31.) 4.563 0.093 49.302 0.000 4.563 2.758
## .pop2 (.32.) 5.724 0.068 83.874 0.000 5.724 4.546
## .pop3 (.33.) 5.188 0.090 57.700 0.000 5.188 3.217
## .pop4 (.34.) 5.071 0.081 62.412 0.000 5.071 3.310
## .radact1 (.35.) 1.855 0.081 22.865 0.000 1.855 1.253
## .radact2 (.36.) 2.397 0.095 25.123 0.000 2.397 1.405
## .radact3 (.37.) 2.229 0.092 24.148 0.000 2.229 1.357
## .radact5 (.38.) 2.200 0.087 25.189 0.000 2.200 1.409
## .radact6 (.39.) 2.887 0.098 29.450 0.000 2.887 1.587
## pop -0.015 0.107 -0.136 0.892 -0.012 -0.012
## .rpa 0.140 0.093 1.510 0.131 0.131 0.131
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 (.14.) 0.535 0.111 4.822 0.000 0.535 0.271
## .ant2 (.15.) 0.737 0.118 6.251 0.000 0.737 0.370
## .ant3 (.16.) 1.036 0.136 7.631 0.000 1.036 0.503
## .ant5 (.17.) 1.458 0.161 9.045 0.000 1.458 0.532
## .pop2 (.18.) 1.190 0.142 8.377 0.000 1.190 0.751
## .pop3 (.19.) 1.561 0.207 7.543 0.000 1.561 0.600
## .pop4 (.20.) 1.859 0.170 10.968 0.000 1.859 0.792
## .radact1 (.21.) 1.044 0.151 6.905 0.000 1.044 0.476
## .radact2 (.22.) 0.993 0.227 4.376 0.000 0.993 0.341
## .radact3 (.23.) 0.693 0.169 4.106 0.000 0.693 0.257
## .radact5 (.24.) 0.754 0.179 4.224 0.000 0.754 0.309
## .radact6 (.25.) 2.008 0.215 9.351 0.000 2.008 0.606
## pop (.26.) 1.443 0.153 9.430 0.000 1.000 1.000
## .rpa (.27.) 1.112 0.189 5.890 0.000 0.968 0.968
##
## R-Square:
## Estimate
## ant1 0.729
## ant2 0.630
## ant3 0.497
## ant5 0.468
## pop2 0.249
## pop3 0.400
## pop4 0.208
## radact1 0.524
## radact2 0.659
## radact3 0.743
## radact5 0.691
## radact6 0.394
## rpa 0.032
par(mfrow=c(2,2))
semPaths(US_NE_r_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
semPaths(US_NE_f_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
dev.off()
## null device
## 1
convert the experimental treatment into factor
DE1$EXPTRT <- factor(DE1$EXPTRT, levels = c(0,3), labels = c("Control","Treatment"))
DE_S1_measure.model <-'
pc =~ POPpc3 + POPpc1
ae =~ POPae3 + POPae1
mw =~ POPmwv3 + POPmwv1
'
measure.cfa.fit <-cfa(DE_S1_measure.model, DE1, estimator='mlr', mimic='mplus',missing='fiml', sample.mean=T)
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: some cases are empty and will be ignored:
## 13 125 158 266
range01 <- function(x){(x-min(x,na.rm=T))/(max(x,na.rm=T)-min(x,na.rm=T))}
dimensions<-predict(measure.cfa.fit)[,1:3]
dimensions<-apply(dimensions,2,range01)
pop_DE1<-dimensions[,1]*dimensions[,2]*dimensions[,3]
DE1$pop<-pop_DE1
DE1_model_PE <-'
gc =~ alwVote + KWAoGov + ActSocPol
gc ~ pop # regression
'
DE1_PE_r_fit <- sem (DE1_model_PE,DE1, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances",
"regressions"),
group.partial=c("means"))
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 3 cases were deleted in group Control due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 1 cases were deleted in group Treatment due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
DE1_PE_f_fit <- sem (DE1_model_PE,DE1, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances"),
group.partial=c("regressions", "means"))
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 3 cases were deleted in group Control due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 1 cases were deleted in group Treatment due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
anova(DE1_PE_r_fit, DE1_PE_f_fit)
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## DE1_PE_f_fit 12 3102.1 3146.6 17.593
## DE1_PE_r_fit 13 3100.9 3141.6 18.354 0.73563 1 0.3911
cf <- compareFit(DE1_PE_r_fit, DE1_PE_f_fit, nested=T)
summary(cf)
## ################### Nested Model Comparison #########################
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## DE1_PE_f_fit 12 3102.1 3146.6 17.593
## DE1_PE_r_fit 13 3100.9 3141.6 18.354 0.73563 1 0.3911
##
## ####################### Model Fit Indices ###########################
## chisq.scaled df.scaled pvalue.scaled cfi.robust tli.robust
## DE1_PE_f_fit 16.406† 12 .173 .958 .958
## DE1_PE_r_fit 17.163 13 .192 .961† .964†
## aic bic rmsea.robust srmr
## DE1_PE_f_fit 3102.127 3146.573 .051 .053†
## DE1_PE_r_fit 3100.888† 3141.630† .048† .056
##
## ################## Differences in Fit Indices #######################
## df.scaled cfi.robust tli.robust aic bic
## DE1_PE_r_fit - DE1_PE_r_fit 1 0.002 0.005 -1.239 -4.943
## rmsea.robust srmr
## DE1_PE_r_fit - DE1_PE_r_fit -0.003 0.003
summary(DE1_PE_r_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 40 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 21
## Number of equality constraints 10
## Row rank of the constraints matrix 10
##
## Used Total
## Number of observations per group
## Control 154 157
## Treatment 146 147
## Number of missing patterns per group
## Control 2
## Treatment 2
##
## Model Fit Test Statistic 18.354 17.163
## Degrees of freedom 13 13
## P-value (Chi-square) 0.145 0.192
## Scaling correction factor 1.069
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## Control 9.173 8.578
## Treatment 9.181 8.585
##
## Model test baseline model:
##
## Minimum Function Test Statistic 125.848 118.841
## Degrees of freedom 12 12
## P-value 0.000 0.000
## Scaling correction factor 1.059
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.953 0.961
## Tucker-Lewis Index (TLI) 0.957 0.964
##
## Robust Comparative Fit Index (CFI) 0.961
## Robust Tucker-Lewis Index (TLI) 0.964
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -1539.444 -1539.444
## Scaling correction factor 0.610
## for the MLR correction
## Loglikelihood unrestricted model (H1) -1530.267 -1530.267
## Scaling correction factor 1.113
## for the MLR correction
##
## Number of free parameters 11 11
## Akaike (AIC) 3100.888 3100.888
## Bayesian (BIC) 3141.630 3141.630
## Sample-size adjusted Bayesian (BIC) 3106.744 3106.744
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.052 0.046
## 90 Percent Confidence Interval 0.000 0.103 0.000 0.097
## P-value RMSEA <= 0.05 0.424 0.497
##
## Robust RMSEA 0.048
## 90 Percent Confidence Interval 0.000 0.102
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.056 0.056
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## gc =~
## alwVote 1.000 0.772 0.525
## KWAoGov (.p2.) 1.091 0.214 5.109 0.000 0.842 0.662
## ActScPl (.p3.) 1.260 0.238 5.282 0.000 0.973 0.625
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## gc ~
## pop (.p4.) -0.237 0.496 -0.479 0.632 -0.307 -0.037
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .alwVote (.10.) 5.738 0.108 53.354 0.000 5.738 3.903
## .KWAoGov (.11.) 5.288 0.111 47.450 0.000 5.288 4.153
## .ActScPl (.12.) 4.487 0.123 36.466 0.000 4.487 2.884
## .gc 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .alwVote (.p5.) 1.565 0.226 6.928 0.000 1.565 0.724
## .KWAoGov (.p6.) 0.911 0.155 5.887 0.000 0.911 0.562
## .ActScPl (.p7.) 1.474 0.225 6.552 0.000 1.474 0.609
## .gc (.p8.) 0.595 0.184 3.237 0.001 0.999 0.999
##
## R-Square:
## Estimate
## alwVote 0.276
## KWAoGov 0.438
## ActSocPol 0.391
## gc 0.001
##
##
## Group 2 [Treatment]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## gc =~
## alwVote 1.000 0.772 0.525
## KWAoGov (.p2.) 1.091 0.214 5.109 0.000 0.843 0.662
## ActScPl (.p3.) 1.260 0.238 5.282 0.000 0.973 0.625
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## gc ~
## pop (.p4.) -0.237 0.496 -0.479 0.632 -0.307 -0.040
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .alwVote (.10.) 5.738 0.108 53.354 0.000 5.738 3.903
## .KWAoGov (.11.) 5.288 0.111 47.450 0.000 5.288 4.153
## .ActScPl (.12.) 4.487 0.123 36.466 0.000 4.487 2.884
## .gc 0.201 0.116 1.729 0.084 0.260 0.260
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .alwVote (.p5.) 1.565 0.226 6.928 0.000 1.565 0.724
## .KWAoGov (.p6.) 0.911 0.155 5.887 0.000 0.911 0.562
## .ActScPl (.p7.) 1.474 0.225 6.552 0.000 1.474 0.609
## .gc (.p8.) 0.595 0.184 3.237 0.001 0.998 0.998
##
## R-Square:
## Estimate
## alwVote 0.276
## KWAoGov 0.438
## ActSocPol 0.391
## gc 0.002
summary(DE1_PE_f_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 44 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 21
## Number of equality constraints 9
## Row rank of the constraints matrix 9
##
## Used Total
## Number of observations per group
## Control 154 157
## Treatment 146 147
## Number of missing patterns per group
## Control 2
## Treatment 2
##
## Model Fit Test Statistic 17.593 16.406
## Degrees of freedom 12 12
## P-value (Chi-square) 0.129 0.173
## Scaling correction factor 1.072
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## Control 9.016 8.408
## Treatment 8.577 7.999
##
## Model test baseline model:
##
## Minimum Function Test Statistic 125.848 118.841
## Degrees of freedom 12 12
## P-value 0.000 0.000
## Scaling correction factor 1.059
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.951 0.959
## Tucker-Lewis Index (TLI) 0.951 0.959
##
## Robust Comparative Fit Index (CFI) 0.958
## Robust Tucker-Lewis Index (TLI) 0.958
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -1539.064 -1539.064
## Scaling correction factor 0.659
## for the MLR correction
## Loglikelihood unrestricted model (H1) -1530.267 -1530.267
## Scaling correction factor 1.113
## for the MLR correction
##
## Number of free parameters 12 12
## Akaike (AIC) 3102.127 3102.127
## Bayesian (BIC) 3146.573 3146.573
## Sample-size adjusted Bayesian (BIC) 3108.516 3108.516
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.056 0.049
## 90 Percent Confidence Interval 0.000 0.108 0.000 0.102
## P-value RMSEA <= 0.05 0.386 0.458
##
## Robust RMSEA 0.051
## 90 Percent Confidence Interval 0.000 0.107
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.053 0.053
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## gc =~
## alwVote 1.000 0.769 0.523
## KWAoGov (.p2.) 1.086 0.209 5.189 0.000 0.835 0.656
## ActScPl (.p3.) 1.273 0.247 5.163 0.000 0.978 0.629
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## gc ~
## pop 0.169 0.633 0.266 0.790 0.219 0.026
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .alwVote (.10.) 5.700 0.114 50.033 0.000 5.700 3.880
## .KWAoGov (.11.) 5.247 0.121 43.473 0.000 5.247 4.125
## .ActScPl (.12.) 4.438 0.138 32.164 0.000 4.438 2.855
## .gc 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .alwVote (.p5.) 1.567 0.226 6.946 0.000 1.567 0.726
## .KWAoGov (.p6.) 0.921 0.156 5.886 0.000 0.921 0.569
## .ActScPl (.p7.) 1.458 0.231 6.309 0.000 1.458 0.604
## .gc (.p8.) 0.590 0.183 3.228 0.001 0.999 0.999
##
## R-Square:
## Estimate
## alwVote 0.274
## KWAoGov 0.431
## ActSocPol 0.396
## gc 0.001
##
##
## Group 2 [Treatment]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## gc =~
## alwVote 1.000 0.772 0.525
## KWAoGov (.p2.) 1.086 0.209 5.189 0.000 0.839 0.658
## ActScPl (.p3.) 1.273 0.247 5.163 0.000 0.983 0.631
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## gc ~
## pop -0.608 0.694 -0.877 0.381 -0.787 -0.103
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .alwVote (.10.) 5.700 0.114 50.033 0.000 5.700 3.874
## .KWAoGov (.11.) 5.247 0.121 43.473 0.000 5.247 4.116
## .ActScPl (.12.) 4.438 0.138 32.164 0.000 4.438 2.850
## .gc 0.274 0.143 1.922 0.055 0.355 0.355
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .alwVote (.p5.) 1.567 0.226 6.946 0.000 1.567 0.724
## .KWAoGov (.p6.) 0.921 0.156 5.886 0.000 0.921 0.567
## .ActScPl (.p7.) 1.458 0.231 6.309 0.000 1.458 0.601
## .gc (.p8.) 0.590 0.183 3.228 0.001 0.989 0.989
##
## R-Square:
## Estimate
## alwVote 0.276
## KWAoGov 0.433
## ActSocPol 0.399
## gc 0.011
par(mfrow=c(2,2))
semPaths(DE1_PE_r_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
semPaths(DE1_PE_f_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
dev.off()
## null device
## 1
DE1_model_NE <-'
vot =~ a*vp1 + a*vp3 # not voting
vot ~ pop # regression
'
DE1_NE_r_fit <- sem (DE1_model_NE, DE1, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances",
"regressions"),
group.partial=c("means"))
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 3 cases were deleted in group Control due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 1 cases were deleted in group Treatment due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
DE1_NE_f_fit <- sem (DE1_model_NE, DE1, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances"),
group.partial=c("regressions", "means"))
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 3 cases were deleted in group Control due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 1 cases were deleted in group Treatment due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
anova(DE1_NE_r_fit, DE1_NE_f_fit)
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## DE1_NE_f_fit 6 2279.5 2309.2 1.6650
## DE1_NE_r_fit 7 2278.4 2304.3 2.4931 0.73153 1 0.3924
cf <- compareFit(DE1_NE_r_fit, DE1_NE_f_fit, nested=T)
summary(cf)
## ################### Nested Model Comparison #########################
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## DE1_NE_f_fit 6 2279.5 2309.2 1.6650
## DE1_NE_r_fit 7 2278.4 2304.3 2.4931 0.73153 1 0.3924
##
## ####################### Model Fit Indices ###########################
## chisq.scaled df.scaled pvalue.scaled cfi.robust tli.robust
## DE1_NE_f_fit 1.323† 6 .970 1.000† 1.088†
## DE1_NE_r_fit 2.009 7 .959 1.000† 1.079
## aic bic rmsea.robust srmr
## DE1_NE_f_fit 2279.542 2309.172 .000† .017†
## DE1_NE_r_fit 2278.370† 2304.297† .000† .027
##
## ################## Differences in Fit Indices #######################
## df.scaled cfi.robust tli.robust aic bic
## DE1_NE_r_fit - DE1_NE_r_fit 1 0 -0.009 -1.172 -4.876
## rmsea.robust srmr
## DE1_NE_r_fit - DE1_NE_r_fit 0 0.01
summary(DE1_NE_r_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 29 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 13
## Number of equality constraints 6
## Row rank of the constraints matrix 6
##
## Used Total
## Number of observations per group
## Control 154 157
## Treatment 146 147
## Number of missing patterns per group
## Control 2
## Treatment 2
##
## Model Fit Test Statistic 2.493 2.009
## Degrees of freedom 7 7
## P-value (Chi-square) 0.928 0.959
## Scaling correction factor 1.241
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## Control 1.472 1.186
## Treatment 1.021 0.823
##
## Model test baseline model:
##
## Minimum Function Test Statistic 75.614 53.135
## Degrees of freedom 6 6
## P-value 0.000 0.000
## Scaling correction factor 1.423
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 1.000 1.000
## Tucker-Lewis Index (TLI) 1.055 1.091
##
## Robust Comparative Fit Index (CFI) 1.000
## Robust Tucker-Lewis Index (TLI) 1.079
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -1132.185 -1132.185
## Scaling correction factor 0.656
## for the MLR correction
## Loglikelihood unrestricted model (H1) -1130.938 -1130.938
## Scaling correction factor 1.229
## for the MLR correction
##
## Number of free parameters 7 7
## Akaike (AIC) 2278.370 2278.370
## Bayesian (BIC) 2304.297 2304.297
## Sample-size adjusted Bayesian (BIC) 2282.097 2282.097
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.000 0.000
## 90 Percent Confidence Interval 0.000 0.031 0.000 0.000
## P-value RMSEA <= 0.05 0.973 0.993
##
## Robust RMSEA 0.000
## 90 Percent Confidence Interval 0.000 0.000
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.027 0.027
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## vot =~
## vp1 (a) 1.000 1.174 0.687
## vp3 (a) 1.000 1.174 0.678
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## vot ~
## pop (.p3.) 0.470 0.740 0.635 0.525 0.400 0.048
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .vp1 (.p8.) 2.338 0.148 15.781 0.000 2.338 1.368
## .vp3 (.p9.) 2.939 0.148 19.903 0.000 2.939 1.698
## .vot 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .vp1 (.p4.) 1.542 0.236 6.520 0.000 1.542 0.528
## .vp3 (.p5.) 1.618 0.244 6.622 0.000 1.618 0.540
## .vot (.p6.) 1.376 0.220 6.243 0.000 0.998 0.998
##
## R-Square:
## Estimate
## vp1 0.472
## vp3 0.460
## vot 0.002
##
##
## Group 2 [Treatment]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## vot =~
## vp1 (a) 1.000 1.175 0.687
## vp3 (a) 1.000 1.175 0.678
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## vot ~
## pop (.p3.) 0.470 0.740 0.635 0.525 0.400 0.052
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .vp1 (.p8.) 2.338 0.148 15.781 0.000 2.338 1.368
## .vp3 (.p9.) 2.939 0.148 19.903 0.000 2.939 1.698
## .vot -0.110 0.171 -0.645 0.519 -0.094 -0.094
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .vp1 (.p4.) 1.542 0.236 6.520 0.000 1.542 0.528
## .vp3 (.p5.) 1.618 0.244 6.622 0.000 1.618 0.540
## .vot (.p6.) 1.376 0.220 6.243 0.000 0.997 0.997
##
## R-Square:
## Estimate
## vp1 0.472
## vp3 0.460
## vot 0.003
summary(DE1_NE_f_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 40 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 13
## Number of equality constraints 5
## Row rank of the constraints matrix 5
##
## Used Total
## Number of observations per group
## Control 154 157
## Treatment 146 147
## Number of missing patterns per group
## Control 2
## Treatment 2
##
## Model Fit Test Statistic 1.665 1.323
## Degrees of freedom 6 6
## P-value (Chi-square) 0.948 0.970
## Scaling correction factor 1.259
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## Control 1.017 0.808
## Treatment 0.648 0.515
##
## Model test baseline model:
##
## Minimum Function Test Statistic 75.614 53.135
## Degrees of freedom 6 6
## P-value 0.000 0.000
## Scaling correction factor 1.423
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 1.000 1.000
## Tucker-Lewis Index (TLI) 1.062 1.099
##
## Robust Comparative Fit Index (CFI) 1.000
## Robust Tucker-Lewis Index (TLI) 1.088
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -1131.771 -1131.771
## Scaling correction factor 0.743
## for the MLR correction
## Loglikelihood unrestricted model (H1) -1130.938 -1130.938
## Scaling correction factor 1.229
## for the MLR correction
##
## Number of free parameters 8 8
## Akaike (AIC) 2279.542 2279.542
## Bayesian (BIC) 2309.172 2309.172
## Sample-size adjusted Bayesian (BIC) 2283.801 2283.801
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.000 0.000
## 90 Percent Confidence Interval 0.000 0.011 0.000 0.000
## P-value RMSEA <= 0.05 0.979 0.995
##
## Robust RMSEA 0.000
## 90 Percent Confidence Interval 0.000 0.000
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.017 0.017
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## vot =~
## vp1 (a) 1.000 1.171 0.687
## vp3 (a) 1.000 1.171 0.676
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## vot ~
## pop -0.185 1.038 -0.179 0.858 -0.158 -0.019
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .vp1 (.p8.) 2.399 0.165 14.532 0.000 2.399 1.408
## .vp3 (.p9.) 2.999 0.161 18.608 0.000 2.999 1.733
## .vot 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .vp1 (.p4.) 1.533 0.234 6.553 0.000 1.533 0.528
## .vp3 (.p5.) 1.626 0.244 6.657 0.000 1.626 0.543
## .vot (.p6.) 1.370 0.220 6.217 0.000 1.000 1.000
##
## R-Square:
## Estimate
## vp1 0.472
## vp3 0.457
## vot 0.000
##
##
## Group 2 [Treatment]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## vot =~
## vp1 (a) 1.000 1.179 0.689
## vp3 (a) 1.000 1.179 0.679
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## vot ~
## pop 1.055 1.035 1.019 0.308 0.895 0.117
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .vp1 (.p8.) 2.399 0.165 14.532 0.000 2.399 1.403
## .vp3 (.p9.) 2.999 0.161 18.608 0.000 2.999 1.727
## .vot -0.226 0.218 -1.040 0.299 -0.192 -0.192
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .vp1 (.p4.) 1.533 0.234 6.553 0.000 1.533 0.525
## .vp3 (.p5.) 1.626 0.244 6.657 0.000 1.626 0.539
## .vot (.p6.) 1.370 0.220 6.217 0.000 0.986 0.986
##
## R-Square:
## Estimate
## vp1 0.475
## vp3 0.461
## vot 0.014
par(mfrow=c(2,2))
semPaths(DE1_NE_r_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
semPaths(DE1_NE_f_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
dev.off()
## null device
## 1
convert into factor
DE2$EXPTRT <- factor(DE2$EXPTRT, levels = c(0,1,2), labels = c("Control","PEGIDA","LEIPZIG"))
DE2_measure.model <- '
pc =~ POPpc1 + POPpc2 + POPpc3 # people-centrism
ae =~ POPae1 + POPae2 + POPae3 # anti-elitism
mw =~ POPmw1 + POPmw2 + POPmw3 # manichean view of politics
'
DE2_measure.cfa <- cfa(DE2_measure.model, DE2, estimator='mlr', mimic='mplus',missing='fiml', sample.mean=T)
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: some cases are empty and will be ignored:
## 170 171
range01 <- function(x){(x-min(x,na.rm=T))/(max(x,na.rm=T)-min(x,na.rm=T))}
dimensions<-predict(DE2_measure.cfa)[,1:3]
dimensions<-apply(dimensions,2,range01)
pop_DE2 <- dimensions[,1]*dimensions[,2]*dimensions[,3]
DE2$pop<-pop_DE2
DE2_model <- '
dsim =~ GrpIDdsim1 + GrpIDdsim2 + GrpIDdsim3 # group dissimilarity
datt =~ GrpIDdatt1 + GrpIDdatt2 + GrpIDdatt3 # group detachment
dsim ~~ datt # correlation between endogeneous variables
dsim ~ pop # regression
datt ~ pop # regression
'
DE2_r_fit <- sem (DE2_model,DE2, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("loadings", "intercepts",
"residuals", "residual.covariances", "lv.variances", "lv.covariances",
"regressions"),
group.partial=c("means"))
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 1 cases were deleted in group PEGIDA due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 1 cases were deleted in group LEIPZIG due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
DE2_f_fit <- sem (DE2_model,DE2, estimator="mlr", mimic="mplus", missing="fiml",
group = "EXPTRT", sample.mean = T,
group.equal=c("residuals", "residual.covariances", "lv.variances", "lv.covariances"),
group.partial=c("loadings", "intercepts", "regressions", "means"))
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 1 cases were deleted in group PEGIDA due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: 1 cases were deleted in group LEIPZIG due to missing values in
## exogenous variable(s), while fixed.x = TRUE.
anova(DE2_r_fit, DE2_f_fit)
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## DE2_f_fit 54 4423.9 4595.2 154.36
## DE2_r_fit 74 4417.5 4512.8 188.02 36.734 20 0.01259 *
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
cf <- compareFit(DE2_r_fit, DE2_f_fit, nested=T)
summary(cf)
## ################### Nested Model Comparison #########################
## Scaled Chi Square Difference Test (method = "satorra.bentler.2001")
##
## Df AIC BIC Chisq Chisq diff Df diff Pr(>Chisq)
## DE2_f_fit 54 4423.9 4595.2 154.36
## DE2_r_fit 74 4417.5 4512.8 188.02 36.734 20 0.01259 *
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## ####################### Model Fit Indices ###########################
## chisq.scaled df.scaled pvalue.scaled cfi.robust tli.robust
## DE2_f_fit 107.985† 54 .000 .926† .913
## DE2_r_fit 145.665 74 .000 .911 .924†
## aic bic rmsea.robust srmr
## DE2_f_fit 4423.878 4595.245 .113 .163†
## DE2_r_fit 4417.548† 4512.751† .106† .179
##
## ################## Differences in Fit Indices #######################
## df.scaled cfi.robust tli.robust aic bic
## DE2_r_fit - DE2_r_fit 20 -0.015 0.011 -6.331 -82.493
## rmsea.robust srmr
## DE2_r_fit - DE2_r_fit -0.007 0.015
summary(DE2_r_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 57 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 67
## Number of equality constraints 42
## Row rank of the constraints matrix 42
##
## Used Total
## Number of observations per group
## PEGIDA 134 135
## Control 95 95
## LEIPZIG 104 105
## Number of missing patterns per group
## PEGIDA 3
## Control 3
## LEIPZIG 3
##
## Model Fit Test Statistic 188.025 145.665
## Degrees of freedom 74 74
## P-value (Chi-square) 0.000 0.000
## Scaling correction factor 1.291
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## PEGIDA 56.605 43.853
## Control 59.709 46.257
## LEIPZIG 71.711 55.555
##
## Model test baseline model:
##
## Minimum Function Test Statistic 1130.088 793.058
## Degrees of freedom 63 63
## P-value 0.000 0.000
## Scaling correction factor 1.425
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.893 0.902
## Tucker-Lewis Index (TLI) 0.909 0.916
##
## Robust Comparative Fit Index (CFI) 0.911
## Robust Tucker-Lewis Index (TLI) 0.924
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -2183.774 -2183.774
## Scaling correction factor 0.511
## for the MLR correction
## Loglikelihood unrestricted model (H1) -2089.761 -2089.761
## Scaling correction factor 1.311
## for the MLR correction
##
## Number of free parameters 25 25
## Akaike (AIC) 4417.548 4417.548
## Bayesian (BIC) 4512.751 4512.751
## Sample-size adjusted Bayesian (BIC) 4433.450 4433.450
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.118 0.093
## 90 Percent Confidence Interval 0.097 0.139 0.074 0.113
## P-value RMSEA <= 0.05 0.000 0.000
##
## Robust RMSEA 0.106
## 90 Percent Confidence Interval 0.080 0.131
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.179 0.179
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [PEGIDA]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim =~
## GrpIDd1 1.000 0.804 0.826
## GrpIDd2 (.p2.) 0.865 0.050 17.420 0.000 0.696 0.721
## GrpIDd3 (.p3.) 0.964 0.039 24.455 0.000 0.775 0.815
## datt =~
## GrpIDd1 1.000 0.795 0.793
## GrpIDd2 (.p5.) 0.987 0.042 23.390 0.000 0.784 0.806
## GrpIDd3 (.p6.) 1.017 0.046 22.229 0.000 0.809 0.797
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim ~
## pop (.p8.) 0.307 0.353 0.870 0.384 0.382 0.049
## datt ~
## pop (.p9.) 0.148 0.324 0.457 0.648 0.186 0.024
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .dsim ~~
## .datt (.p7.) 0.546 0.063 8.661 0.000 0.855 0.855
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.19.) 3.973 0.096 41.362 0.000 3.973 4.082
## .GrpIDd2 (.20.) 4.073 0.096 42.371 0.000 4.073 4.224
## .GrpIDd3 (.21.) 4.072 0.093 43.967 0.000 4.072 4.279
## .GrpIDd1 (.22.) 4.493 0.086 52.391 0.000 4.493 4.483
## .GrpIDd2 (.23.) 4.208 0.093 45.415 0.000 4.208 4.324
## .GrpIDd3 (.24.) 4.191 0.094 44.638 0.000 4.191 4.134
## .dsim 0.000 0.000 0.000
## .datt 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.10.) 0.301 0.042 7.238 0.000 0.301 0.317
## .GrpIDd2 (.11.) 0.446 0.094 4.743 0.000 0.446 0.480
## .GrpIDd3 (.12.) 0.305 0.043 7.068 0.000 0.305 0.336
## .GrpIDd1 (.13.) 0.373 0.071 5.230 0.000 0.373 0.371
## .GrpIDd2 (.14.) 0.332 0.057 5.771 0.000 0.332 0.350
## .GrpIDd3 (.15.) 0.374 0.057 6.588 0.000 0.374 0.364
## .dsim (.16.) 0.645 0.072 9.000 0.000 0.998 0.998
## .datt (.17.) 0.631 0.067 9.372 0.000 0.999 0.999
##
## R-Square:
## Estimate
## GrpIDdsim1 0.683
## GrpIDdsim2 0.520
## GrpIDdsim3 0.664
## GrpIDdatt1 0.629
## GrpIDdatt2 0.650
## GrpIDdatt3 0.636
## dsim 0.002
## datt 0.001
##
##
## Group 2 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim =~
## GrpIDd1 1.000 0.804 0.826
## GrpIDd2 (.p2.) 0.865 0.050 17.420 0.000 0.696 0.721
## GrpIDd3 (.p3.) 0.964 0.039 24.455 0.000 0.775 0.815
## datt =~
## GrpIDd1 1.000 0.795 0.793
## GrpIDd2 (.p5.) 0.987 0.042 23.390 0.000 0.784 0.806
## GrpIDd3 (.p6.) 1.017 0.046 22.229 0.000 0.809 0.797
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim ~
## pop (.p8.) 0.307 0.353 0.870 0.384 0.382 0.054
## datt ~
## pop (.p9.) 0.148 0.324 0.457 0.648 0.186 0.026
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .dsim ~~
## .datt (.p7.) 0.546 0.063 8.661 0.000 0.855 0.855
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.19.) 3.973 0.096 41.362 0.000 3.973 4.082
## .GrpIDd2 (.20.) 4.073 0.096 42.371 0.000 4.073 4.223
## .GrpIDd3 (.21.) 4.072 0.093 43.967 0.000 4.072 4.278
## .GrpIDd1 (.22.) 4.493 0.086 52.391 0.000 4.493 4.483
## .GrpIDd2 (.23.) 4.208 0.093 45.415 0.000 4.208 4.324
## .GrpIDd3 (.24.) 4.191 0.094 44.638 0.000 4.191 4.134
## .dsim -1.606 0.130 -12.364 0.000 -1.996 -1.996
## .datt -1.860 0.134 -13.853 0.000 -2.340 -2.340
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.10.) 0.301 0.042 7.238 0.000 0.301 0.317
## .GrpIDd2 (.11.) 0.446 0.094 4.743 0.000 0.446 0.480
## .GrpIDd3 (.12.) 0.305 0.043 7.068 0.000 0.305 0.336
## .GrpIDd1 (.13.) 0.373 0.071 5.230 0.000 0.373 0.371
## .GrpIDd2 (.14.) 0.332 0.057 5.771 0.000 0.332 0.350
## .GrpIDd3 (.15.) 0.374 0.057 6.588 0.000 0.374 0.364
## .dsim (.16.) 0.645 0.072 9.000 0.000 0.997 0.997
## .datt (.17.) 0.631 0.067 9.372 0.000 0.999 0.999
##
## R-Square:
## Estimate
## GrpIDdsim1 0.683
## GrpIDdsim2 0.520
## GrpIDdsim3 0.664
## GrpIDdatt1 0.629
## GrpIDdatt2 0.650
## GrpIDdatt3 0.636
## dsim 0.003
## datt 0.001
##
##
## Group 3 [LEIPZIG]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim =~
## GrpIDd1 1.000 0.804 0.826
## GrpIDd2 (.p2.) 0.865 0.050 17.420 0.000 0.695 0.721
## GrpIDd3 (.p3.) 0.964 0.039 24.455 0.000 0.775 0.815
## datt =~
## GrpIDd1 1.000 0.795 0.793
## GrpIDd2 (.p5.) 0.987 0.042 23.390 0.000 0.784 0.806
## GrpIDd3 (.p6.) 1.017 0.046 22.229 0.000 0.809 0.797
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim ~
## pop (.p8.) 0.307 0.353 0.870 0.384 0.382 0.046
## datt ~
## pop (.p9.) 0.148 0.324 0.457 0.648 0.186 0.022
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .dsim ~~
## .datt (.p7.) 0.546 0.063 8.661 0.000 0.855 0.855
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.19.) 3.973 0.096 41.362 0.000 3.973 4.083
## .GrpIDd2 (.20.) 4.073 0.096 42.371 0.000 4.073 4.224
## .GrpIDd3 (.21.) 4.072 0.093 43.967 0.000 4.072 4.279
## .GrpIDd1 (.22.) 4.493 0.086 52.391 0.000 4.493 4.483
## .GrpIDd2 (.23.) 4.208 0.093 45.415 0.000 4.208 4.324
## .GrpIDd3 (.24.) 4.191 0.094 44.638 0.000 4.191 4.134
## .dsim -1.375 0.117 -11.716 0.000 -1.710 -1.710
## .datt -1.655 0.126 -13.087 0.000 -2.082 -2.082
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.10.) 0.301 0.042 7.238 0.000 0.301 0.317
## .GrpIDd2 (.11.) 0.446 0.094 4.743 0.000 0.446 0.480
## .GrpIDd3 (.12.) 0.305 0.043 7.068 0.000 0.305 0.336
## .GrpIDd1 (.13.) 0.373 0.071 5.230 0.000 0.373 0.371
## .GrpIDd2 (.14.) 0.332 0.057 5.771 0.000 0.332 0.350
## .GrpIDd3 (.15.) 0.374 0.057 6.588 0.000 0.374 0.364
## .dsim (.16.) 0.645 0.072 9.000 0.000 0.998 0.998
## .datt (.17.) 0.631 0.067 9.372 0.000 0.999 0.999
##
## R-Square:
## Estimate
## GrpIDdsim1 0.683
## GrpIDdsim2 0.520
## GrpIDdsim3 0.664
## GrpIDdatt1 0.629
## GrpIDdatt2 0.650
## GrpIDdatt3 0.636
## dsim 0.002
## datt 0.001
summary(DE2_f_fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 88 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 63
## Number of equality constraints 18
## Row rank of the constraints matrix 18
##
## Used Total
## Number of observations per group
## PEGIDA 134 135
## Control 95 95
## LEIPZIG 104 105
## Number of missing patterns per group
## PEGIDA 3
## Control 3
## LEIPZIG 3
##
## Model Fit Test Statistic 154.355 107.985
## Degrees of freedom 54 54
## P-value (Chi-square) 0.000 0.000
## Scaling correction factor 1.429
## for the Yuan-Bentler correction (Mplus variant)
##
## Chi-square for each group:
##
## PEGIDA 36.355 25.434
## Control 57.941 40.535
## LEIPZIG 60.059 42.017
##
## Model test baseline model:
##
## Minimum Function Test Statistic 1130.088 793.058
## Degrees of freedom 63 63
## P-value 0.000 0.000
## Scaling correction factor 1.425
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.906 0.926
## Tucker-Lewis Index (TLI) 0.890 0.914
##
## Robust Comparative Fit Index (CFI) 0.926
## Robust Tucker-Lewis Index (TLI) 0.913
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -2166.939 -2166.939
## Scaling correction factor 0.835
## for the MLR correction
## Loglikelihood unrestricted model (H1) -2089.761 -2089.761
## Scaling correction factor 1.311
## for the MLR correction
##
## Number of free parameters 45 45
## Akaike (AIC) 4423.878 4423.878
## Bayesian (BIC) 4595.245 4595.245
## Sample-size adjusted Bayesian (BIC) 4452.502 4452.502
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.129 0.095
## 90 Percent Confidence Interval 0.106 0.154 0.073 0.117
## P-value RMSEA <= 0.05 0.000 0.001
##
## Robust RMSEA 0.113
## 90 Percent Confidence Interval 0.082 0.144
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.163 0.163
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
##
## Group 1 [PEGIDA]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim =~
## GrpIDdsim1 1.000 0.809 0.828
## GrpIDdsim2 0.844 0.091 9.228 0.000 0.682 0.713
## GrpIDdsim3 1.069 0.082 12.987 0.000 0.864 0.848
## datt =~
## GrpIDdatt1 1.000 0.719 0.758
## GrpIDdatt2 1.239 0.153 8.088 0.000 0.890 0.849
## GrpIDdatt3 1.334 0.150 8.912 0.000 0.959 0.857
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim ~
## pop 1.345 0.485 2.771 0.006 1.663 0.213
## datt ~
## pop 0.774 0.411 1.885 0.059 1.078 0.138
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .dsim ~~
## .datt (.p7.) 0.474 0.067 7.075 0.000 0.843 0.843
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDdsim1 3.816 0.112 34.135 0.000 3.816 3.907
## .GrpIDdsim2 3.977 0.108 36.719 0.000 3.977 4.156
## .GrpIDdsim3 3.887 0.117 33.345 0.000 3.887 3.814
## .GrpIDdatt1 4.473 0.096 46.714 0.000 4.473 4.717
## .GrpIDdatt2 4.057 0.109 37.305 0.000 4.057 3.867
## .GrpIDdatt3 4.021 0.120 33.575 0.000 4.021 3.592
## .dsim 0.000 0.000 0.000
## .datt 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.10.) 0.300 0.041 7.353 0.000 0.300 0.315
## .GrpIDd2 (.11.) 0.451 0.093 4.832 0.000 0.451 0.492
## .GrpIDd3 (.12.) 0.291 0.044 6.567 0.000 0.291 0.281
## .GrpIDd1 (.13.) 0.383 0.072 5.354 0.000 0.383 0.426
## .GrpIDd2 (.14.) 0.308 0.055 5.594 0.000 0.308 0.280
## .GrpIDd3 (.15.) 0.334 0.052 6.407 0.000 0.334 0.266
## .dsim (.16.) 0.624 0.075 8.300 0.000 0.954 0.954
## .datt (.17.) 0.507 0.079 6.390 0.000 0.981 0.981
##
## R-Square:
## Estimate
## GrpIDdsim1 0.685
## GrpIDdsim2 0.508
## GrpIDdsim3 0.719
## GrpIDdatt1 0.574
## GrpIDdatt2 0.720
## GrpIDdatt3 0.734
## dsim 0.046
## datt 0.019
##
##
## Group 2 [Control]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim =~
## GrpIDdsim1 1.000 0.796 0.824
## GrpIDdsim2 0.829 0.111 7.489 0.000 0.660 0.701
## GrpIDdsim3 0.977 0.107 9.175 0.000 0.778 0.822
## datt =~
## GrpIDdatt1 1.000 0.725 0.761
## GrpIDdatt2 1.086 0.096 11.284 0.000 0.787 0.817
## GrpIDdatt3 1.046 0.103 10.194 0.000 0.758 0.795
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim ~
## pop -0.717 0.520 -1.377 0.168 -0.900 -0.127
## datt ~
## pop -0.980 0.514 -1.907 0.056 -1.352 -0.190
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .dsim ~~
## .datt (.p7.) 0.474 0.067 7.075 0.000 0.843 0.843
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDdsim1 2.464 0.141 17.501 0.000 2.464 2.549
## .GrpIDdsim2 2.866 0.132 21.727 0.000 2.866 3.045
## .GrpIDdsim3 2.722 0.142 19.192 0.000 2.722 2.874
## .GrpIDdatt1 2.800 0.156 17.915 0.000 2.800 2.938
## .GrpIDdatt2 2.597 0.152 17.112 0.000 2.597 2.697
## .GrpIDdatt3 2.460 0.155 15.907 0.000 2.460 2.580
## .dsim 0.000 0.000 0.000
## .datt 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.10.) 0.300 0.041 7.353 0.000 0.300 0.321
## .GrpIDd2 (.11.) 0.451 0.093 4.832 0.000 0.451 0.509
## .GrpIDd3 (.12.) 0.291 0.044 6.567 0.000 0.291 0.325
## .GrpIDd1 (.13.) 0.383 0.072 5.354 0.000 0.383 0.421
## .GrpIDd2 (.14.) 0.308 0.055 5.594 0.000 0.308 0.332
## .GrpIDd3 (.15.) 0.334 0.052 6.407 0.000 0.334 0.367
## .dsim (.16.) 0.624 0.075 8.300 0.000 0.984 0.984
## .datt (.17.) 0.507 0.079 6.390 0.000 0.964 0.964
##
## R-Square:
## Estimate
## GrpIDdsim1 0.679
## GrpIDdsim2 0.491
## GrpIDdsim3 0.675
## GrpIDdatt1 0.579
## GrpIDdatt2 0.668
## GrpIDdatt3 0.633
## dsim 0.016
## datt 0.036
##
##
## Group 3 [LEIPZIG]:
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim =~
## GrpIDdsim1 1.000 0.790 0.822
## GrpIDdsim2 0.844 0.064 13.184 0.000 0.667 0.705
## GrpIDdsim3 0.928 0.083 11.230 0.000 0.733 0.805
## datt =~
## GrpIDdatt1 1.000 0.714 0.756
## GrpIDdatt2 1.132 0.134 8.456 0.000 0.808 0.824
## GrpIDdatt3 1.221 0.124 9.870 0.000 0.871 0.833
##
## Regressions:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## dsim ~
## pop 0.008 0.811 0.010 0.992 0.010 0.001
## datt ~
## pop 0.429 0.608 0.706 0.480 0.602 0.072
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .dsim ~~
## .datt (.p7.) 0.474 0.067 7.075 0.000 0.843 0.843
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDdsim1 2.707 0.131 20.654 0.000 2.707 2.816
## .GrpIDdsim2 2.832 0.117 24.199 0.000 2.832 2.993
## .GrpIDdsim3 2.770 0.127 21.837 0.000 2.770 3.043
## .GrpIDdatt1 2.711 0.122 22.279 0.000 2.711 2.871
## .GrpIDdatt2 2.539 0.136 18.614 0.000 2.539 2.590
## .GrpIDdatt3 2.532 0.145 17.432 0.000 2.532 2.422
## .dsim 0.000 0.000 0.000
## .datt 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .GrpIDd1 (.10.) 0.300 0.041 7.353 0.000 0.300 0.325
## .GrpIDd2 (.11.) 0.451 0.093 4.832 0.000 0.451 0.503
## .GrpIDd3 (.12.) 0.291 0.044 6.567 0.000 0.291 0.352
## .GrpIDd1 (.13.) 0.383 0.072 5.354 0.000 0.383 0.429
## .GrpIDd2 (.14.) 0.308 0.055 5.594 0.000 0.308 0.321
## .GrpIDd3 (.15.) 0.334 0.052 6.407 0.000 0.334 0.306
## .dsim (.16.) 0.624 0.075 8.300 0.000 1.000 1.000
## .datt (.17.) 0.507 0.079 6.390 0.000 0.995 0.995
##
## R-Square:
## Estimate
## GrpIDdsim1 0.675
## GrpIDdsim2 0.497
## GrpIDdsim3 0.648
## GrpIDdatt1 0.571
## GrpIDdatt2 0.679
## GrpIDdatt3 0.694
## dsim 0.000
## datt 0.005
par(mfrow=c(2,2))
semPaths(DE2_r_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
semPaths(DE2_f_fit, "mod", "std", intercept=F, rotation = 2, edge.label.cex=.9, sizeMan = 5, sizeLat = 6, optimizeLatRes=T, ask=F)
dev.off()
## null device
## 1
model <- '
pop =~ ant1 + ant2 + ant3 + ant5 + pop2 + pop3 + pop4 # populist attitudes
ase =~ anes617 + anes616 + anes615 # active support in elections
rpa =~ radact1 + radact2 + radact3 + radact5 + radact6 # legitimate radical political action
'
fit <- cfa (model, data=US, estimator="mlr", mimic="mplus", missing="fiml", std.ov=T, std.lv=T)
summary(fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 24 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 48
##
## Number of observations 646
## Number of missing patterns 574
##
## Model Fit Test Statistic 200.182 163.606
## Degrees of freedom 87 87
## P-value (Chi-square) 0.000 0.000
## Scaling correction factor 1.224
## for the Yuan-Bentler correction (Mplus variant)
##
## Model test baseline model:
##
## Minimum Function Test Statistic 3204.685 2173.598
## Degrees of freedom 105 105
## P-value 0.000 0.000
## Scaling correction factor 1.474
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.963 0.963
## Tucker-Lewis Index (TLI) 0.956 0.955
##
## Robust Comparative Fit Index (CFI) 0.969
## Robust Tucker-Lewis Index (TLI) 0.963
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -7964.492 -7964.492
## Scaling correction factor 1.684
## for the MLR correction
## Loglikelihood unrestricted model (H1) -7864.401 -7864.401
## Scaling correction factor 1.387
## for the MLR correction
##
## Number of free parameters 48 48
## Akaike (AIC) 16024.985 16024.985
## Bayesian (BIC) 16239.583 16239.583
## Sample-size adjusted Bayesian (BIC) 16087.185 16087.185
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.045 0.037
## 90 Percent Confidence Interval 0.037 0.053 0.029 0.045
## P-value RMSEA <= 0.05 0.844 0.998
##
## Robust RMSEA 0.041
## 90 Percent Confidence Interval 0.031 0.050
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.057 0.057
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop =~
## ant1 0.845 0.046 18.304 0.000 0.845 0.844
## ant2 0.801 0.050 15.886 0.000 0.801 0.796
## ant3 0.715 0.053 13.408 0.000 0.715 0.716
## ant5 0.685 0.046 14.794 0.000 0.685 0.688
## pop2 0.501 0.065 7.757 0.000 0.501 0.501
## pop3 0.622 0.052 11.861 0.000 0.622 0.626
## pop4 0.461 0.063 7.325 0.000 0.461 0.459
## ase =~
## anes617 0.931 0.040 23.521 0.000 0.931 0.931
## anes616 0.941 0.035 26.902 0.000 0.941 0.942
## anes615 0.751 0.043 17.481 0.000 0.751 0.752
## rpa =~
## radact1 0.718 0.060 11.940 0.000 0.718 0.721
## radact2 0.800 0.050 16.032 0.000 0.800 0.806
## radact3 0.885 0.052 16.988 0.000 0.885 0.862
## radact5 0.826 0.051 16.246 0.000 0.826 0.830
## radact6 0.623 0.048 12.948 0.000 0.623 0.624
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pop ~~
## ase -0.238 0.049 -4.837 0.000 -0.238 -0.238
## rpa -0.069 0.055 -1.258 0.208 -0.069 -0.069
## ase ~~
## rpa 0.228 0.047 4.807 0.000 0.228 0.228
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 -0.038 0.046 -0.825 0.409 -0.038 -0.038
## .ant2 0.010 0.046 0.212 0.832 0.010 0.010
## .ant3 0.015 0.046 0.324 0.746 0.015 0.015
## .ant5 -0.013 0.046 -0.286 0.775 -0.013 -0.013
## .pop2 0.002 0.049 0.034 0.973 0.002 0.002
## .pop3 -0.000 0.048 -0.008 0.994 -0.000 -0.000
## .pop4 0.023 0.049 0.471 0.638 0.023 0.023
## .anes617 -0.000 0.039 -0.000 1.000 -0.000 -0.000
## .anes616 -0.000 0.039 -0.000 1.000 -0.000 -0.000
## .anes615 -0.000 0.039 -0.000 1.000 -0.000 -0.000
## .radact1 0.002 0.046 0.042 0.967 0.002 0.002
## .radact2 -0.001 0.045 -0.029 0.977 -0.001 -0.001
## .radact3 0.061 0.046 1.322 0.186 0.061 0.060
## .radact5 0.016 0.045 0.363 0.717 0.016 0.016
## .radact6 -0.002 0.047 -0.035 0.972 -0.002 -0.002
## pop 0.000 0.000 0.000
## ase 0.000 0.000 0.000
## rpa 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .ant1 0.287 0.058 4.939 0.000 0.287 0.287
## .ant2 0.371 0.060 6.209 0.000 0.371 0.366
## .ant3 0.484 0.064 7.568 0.000 0.484 0.487
## .ant5 0.522 0.058 9.054 0.000 0.522 0.526
## .pop2 0.751 0.090 8.384 0.000 0.751 0.749
## .pop3 0.600 0.079 7.608 0.000 0.600 0.608
## .pop4 0.793 0.072 11.073 0.000 0.793 0.789
## .anes617 0.132 0.029 4.494 0.000 0.132 0.132
## .anes616 0.113 0.033 3.377 0.001 0.113 0.113
## .anes615 0.434 0.048 8.994 0.000 0.434 0.435
## .radact1 0.477 0.069 6.921 0.000 0.477 0.480
## .radact2 0.345 0.078 4.427 0.000 0.345 0.350
## .radact3 0.270 0.064 4.193 0.000 0.270 0.256
## .radact5 0.307 0.072 4.284 0.000 0.307 0.310
## .radact6 0.609 0.065 9.399 0.000 0.609 0.611
## pop 1.000 1.000 1.000
## ase 1.000 1.000 1.000
## rpa 1.000 1.000 1.000
##
## R-Square:
## Estimate
## ant1 0.713
## ant2 0.634
## ant3 0.513
## ant5 0.474
## pop2 0.251
## pop3 0.392
## pop4 0.211
## anes617 0.868
## anes616 0.887
## anes615 0.565
## radact1 0.520
## radact2 0.650
## radact3 0.744
## radact5 0.690
## radact6 0.389
semPaths(fit, "mod", "std", intercepts = F, edge.label.cex=1, rotation = 4, layout = "tree3")
round(reliability(fit),2)
## pop ase rpa total
## alpha 0.85 0.91 0.88 0.72
## omega 0.85 0.91 0.88 0.86
## omega2 0.85 0.91 0.88 0.86
## omega3 0.84 0.91 0.88 0.87
## avevar 0.46 0.77 0.60 0.57
model <- '
pc =~ POPpc3 + POPpc1 # people-centrism
ae =~ POPae3 + POPae1 # anti-elitism
mw =~ POPmwv3 + POPmwv1 # manichean view of politics
gc =~ alwVote + KWAoGov + ActSocPol # active citizen (+) engagement
vot =~ vp3 + vp1 # not voting (-) engagement
'
fit <- cfa (model, data=DE1, estimator="mlr", mimic="mplus", missing="fiml", std.ov=T, std.lv=T)
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: some cases are empty and will be ignored:
## 13 125 266
summary(fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 59 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 43
##
## Used Total
## Number of observations 301 304
## Number of missing patterns 10
##
## Model Fit Test Statistic 84.035 82.122
## Degrees of freedom 34 34
## P-value (Chi-square) 0.000 0.000
## Scaling correction factor 1.023
## for the Yuan-Bentler correction (Mplus variant)
##
## Model test baseline model:
##
## Minimum Function Test Statistic 661.384 581.224
## Degrees of freedom 55 55
## P-value 0.000 0.000
## Scaling correction factor 1.138
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.917 0.909
## Tucker-Lewis Index (TLI) 0.867 0.852
##
## Robust Comparative Fit Index (CFI) 0.918
## Robust Tucker-Lewis Index (TLI) 0.867
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -4369.867 -4369.867
## Scaling correction factor 1.141
## for the MLR correction
## Loglikelihood unrestricted model (H1) -4327.850 -4327.850
## Scaling correction factor 1.089
## for the MLR correction
##
## Number of free parameters 43 43
## Akaike (AIC) 8825.734 8825.734
## Bayesian (BIC) 8985.140 8985.140
## Sample-size adjusted Bayesian (BIC) 8848.768 8848.768
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.070 0.069
## 90 Percent Confidence Interval 0.051 0.089 0.050 0.087
## P-value RMSEA <= 0.05 0.040 0.050
##
## Robust RMSEA 0.069
## 90 Percent Confidence Interval 0.050 0.089
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.053 0.053
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pc =~
## POPpc3 0.223 0.117 1.901 0.057 0.223 0.223
## POPpc1 0.328 0.176 1.861 0.063 0.328 0.328
## ae =~
## POPae3 0.938 0.139 6.740 0.000 0.938 0.941
## POPae1 0.571 0.099 5.763 0.000 0.571 0.572
## mw =~
## POPmwv3 0.772 0.120 6.438 0.000 0.772 0.773
## POPmwv1 0.390 0.086 4.513 0.000 0.390 0.391
## gc =~
## alwVote 0.993 0.073 13.677 0.000 0.993 0.995
## KWAoGov 0.355 0.072 4.914 0.000 0.355 0.355
## ActSocPol 0.325 0.069 4.714 0.000 0.325 0.325
## vot =~
## vp3 0.852 0.062 13.699 0.000 0.852 0.854
## vp1 0.544 0.075 7.291 0.000 0.544 0.545
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pc ~~
## ae 0.162 0.182 0.887 0.375 0.162 0.162
## mw 0.677 0.321 2.109 0.035 0.677 0.677
## gc 0.288 0.187 1.543 0.123 0.288 0.288
## vot -0.417 0.290 -1.435 0.151 -0.417 -0.417
## ae ~~
## mw 0.413 0.098 4.229 0.000 0.413 0.413
## gc -0.186 0.058 -3.184 0.001 -0.186 -0.186
## vot 0.233 0.071 3.280 0.001 0.233 0.233
## mw ~~
## gc -0.155 0.089 -1.749 0.080 -0.155 -0.155
## vot -0.001 0.093 -0.014 0.989 -0.001 -0.001
## gc ~~
## vot -0.844 0.050 -16.873 0.000 -0.844 -0.844
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .POPpc3 0.000 0.058 0.003 0.998 0.000 0.000
## .POPpc1 0.000 0.058 0.007 0.994 0.000 0.000
## .POPae3 0.001 0.058 0.026 0.979 0.001 0.001
## .POPae1 -0.002 0.058 -0.035 0.972 -0.002 -0.002
## .POPmwv3 -0.003 0.058 -0.047 0.962 -0.003 -0.003
## .POPmwv1 -0.001 0.058 -0.025 0.980 -0.001 -0.001
## .alwVote 0.002 0.057 0.031 0.975 0.002 0.002
## .KWAoGov 0.001 0.058 0.016 0.987 0.001 0.001
## .ActSocPol -0.003 0.058 -0.046 0.963 -0.003 -0.003
## .vp3 -0.004 0.058 -0.063 0.950 -0.004 -0.004
## .vp1 -0.002 0.058 -0.040 0.968 -0.002 -0.002
## pc 0.000 0.000 0.000
## ae 0.000 0.000 0.000
## mw 0.000 0.000 0.000
## gc 0.000 0.000 0.000
## vot 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .POPpc3 0.947 0.082 11.516 0.000 0.947 0.950
## .POPpc1 0.889 0.121 7.322 0.000 0.889 0.892
## .POPae3 0.114 0.257 0.444 0.657 0.114 0.115
## .POPae1 0.670 0.105 6.414 0.000 0.670 0.673
## .POPmwv3 0.400 0.190 2.109 0.035 0.400 0.402
## .POPmwv1 0.845 0.074 11.482 0.000 0.845 0.847
## .alwVote 0.010 0.094 0.103 0.918 0.010 0.010
## .KWAoGov 0.871 0.091 9.612 0.000 0.871 0.874
## .ActSocPol 0.894 0.071 12.661 0.000 0.894 0.895
## .vp3 0.268 0.089 2.998 0.003 0.268 0.270
## .vp1 0.700 0.088 7.945 0.000 0.700 0.703
## pc 1.000 1.000 1.000
## ae 1.000 1.000 1.000
## mw 1.000 1.000 1.000
## gc 1.000 1.000 1.000
## vot 1.000 1.000 1.000
##
## R-Square:
## Estimate
## POPpc3 0.050
## POPpc1 0.108
## POPae3 0.885
## POPae1 0.327
## POPmwv3 0.598
## POPmwv1 0.153
## alwVote 0.990
## KWAoGov 0.126
## ActSocPol 0.105
## vp3 0.730
## vp1 0.297
semPaths(fit, "mod", "std", intercepts = F, edge.label.cex=1, rotation = 4, layout = "tree3")
round(reliability(fit),2)
## pc ae mw gc vot total
## alpha 0.14 0.70 0.46 0.64 0.63 0.30
## omega 0.14 0.74 0.52 0.61 0.67 0.50
## omega2 0.14 0.74 0.52 0.61 0.67 0.50
## omega3 0.14 0.74 0.52 0.54 0.67 0.44
## avevar 0.08 0.61 0.38 0.41 0.51 0.40
model <- '
pc =~ POPpc1 + POPpc2 + POPpc3 # people-centrism
ae =~ POPae1 + POPae2 + POPae3 # anti-elitism
mw =~ POPmw1 + POPmw2 + POPmw3 # manichean view of politics
dsim =~ GrpIDdsim1 + GrpIDdsim2 + GrpIDdsim3 # group dissimilarity
datt =~ GrpIDdatt1 + GrpIDdatt2 + GrpIDdatt3 # group detachment
'
fit <- cfa (model, data=DE2, estimator="mlr", mimic="mplus", missing="fiml", std.ov=T, std.lv=T)
## Warning in lav_data_full(data = data, group = group, cluster = cluster, : lavaan WARNING: some cases are empty and will be ignored:
## 170 171
summary(fit, fit.measures=T, standardized=T, rsquare=T)
## lavaan 0.6-5.1457 ended normally after 44 iterations
##
## Estimator ML
## Optimization method NLMINB
## Number of free parameters 55
##
## Used Total
## Number of observations 333 335
## Number of missing patterns 12
##
## Model Fit Test Statistic 108.014 100.652
## Degrees of freedom 80 80
## P-value (Chi-square) 0.020 0.059
## Scaling correction factor 1.073
## for the Yuan-Bentler correction (Mplus variant)
##
## Model test baseline model:
##
## Minimum Function Test Statistic 2190.837 1800.605
## Degrees of freedom 105 105
## P-value 0.000 0.000
## Scaling correction factor 1.217
##
## User model versus baseline model:
##
## Comparative Fit Index (CFI) 0.987 0.988
## Tucker-Lewis Index (TLI) 0.982 0.984
##
## Robust Comparative Fit Index (CFI) 0.989
## Robust Tucker-Lewis Index (TLI) 0.986
##
## Loglikelihood and Information Criteria:
##
## Loglikelihood user model (H0) -5891.106 -5891.106
## Scaling correction factor 1.285
## for the MLR correction
## Loglikelihood unrestricted model (H1) -5837.099 -5837.099
## Scaling correction factor 1.159
## for the MLR correction
##
## Number of free parameters 55 55
## Akaike (AIC) 11892.211 11892.211
## Bayesian (BIC) 12101.659 12101.659
## Sample-size adjusted Bayesian (BIC) 11927.196 11927.196
##
## Root Mean Square Error of Approximation:
##
## RMSEA 0.032 0.028
## 90 Percent Confidence Interval 0.013 0.047 0.000 0.043
## P-value RMSEA <= 0.05 0.977 0.994
##
## Robust RMSEA 0.029
## 90 Percent Confidence Interval 0.000 0.045
##
## Standardized Root Mean Square Residual:
##
## SRMR 0.041 0.041
##
## Parameter Estimates:
##
## Information Observed
## Observed information based on Hessian
## Standard Errors Robust.huber.white
##
## Latent Variables:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pc =~
## POPpc1 0.596 0.082 7.261 0.000 0.596 0.597
## POPpc2 0.481 0.081 5.963 0.000 0.481 0.481
## POPpc3 0.580 0.086 6.707 0.000 0.580 0.580
## ae =~
## POPae1 0.717 0.062 11.545 0.000 0.717 0.718
## POPae2 0.555 0.063 8.788 0.000 0.555 0.555
## POPae3 0.801 0.064 12.425 0.000 0.801 0.802
## mw =~
## POPmw1 0.636 0.131 4.871 0.000 0.636 0.637
## POPmw2 0.486 0.100 4.841 0.000 0.486 0.487
## POPmw3 0.254 0.115 2.207 0.027 0.254 0.254
## dsim =~
## GrpIDdsim1 0.892 0.035 25.651 0.000 0.892 0.893
## GrpIDdsim2 0.815 0.047 17.237 0.000 0.815 0.816
## GrpIDdsim3 0.886 0.037 23.862 0.000 0.886 0.887
## datt =~
## GrpIDdatt1 0.877 0.035 24.804 0.000 0.877 0.878
## GrpIDdatt2 0.899 0.037 24.488 0.000 0.899 0.901
## GrpIDdatt3 0.895 0.033 26.718 0.000 0.895 0.897
##
## Covariances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## pc ~~
## ae 0.359 0.084 4.272 0.000 0.359 0.359
## mw -0.105 0.114 -0.925 0.355 -0.105 -0.105
## dsim -0.153 0.079 -1.940 0.052 -0.153 -0.153
## datt -0.145 0.077 -1.877 0.061 -0.145 -0.145
## ae ~~
## mw 0.155 0.113 1.374 0.170 0.155 0.155
## dsim -0.054 0.073 -0.736 0.462 -0.054 -0.054
## datt -0.055 0.071 -0.782 0.434 -0.055 -0.055
## mw ~~
## dsim 0.207 0.089 2.327 0.020 0.207 0.207
## datt 0.191 0.107 1.786 0.074 0.191 0.191
## dsim ~~
## datt 0.923 0.019 48.324 0.000 0.923 0.923
##
## Intercepts:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .POPpc1 -0.001 0.055 -0.010 0.992 -0.001 -0.001
## .POPpc2 -0.000 0.055 -0.000 1.000 -0.000 -0.000
## .POPpc3 -0.000 0.055 -0.000 1.000 -0.000 -0.000
## .POPae1 0.002 0.055 0.030 0.976 0.002 0.002
## .POPae2 0.000 0.055 0.002 0.999 0.000 0.000
## .POPae3 0.000 0.055 0.000 1.000 0.000 0.000
## .POPmw1 -0.000 0.055 -0.000 1.000 -0.000 -0.000
## .POPmw2 0.002 0.055 0.045 0.964 0.002 0.002
## .POPmw3 0.000 0.055 0.006 0.995 0.000 0.000
## .GrpIDdsim1 0.002 0.056 0.045 0.964 0.002 0.002
## .GrpIDdsim2 0.002 0.056 0.041 0.968 0.002 0.002
## .GrpIDdsim3 0.002 0.056 0.044 0.965 0.002 0.002
## .GrpIDdatt1 0.000 0.056 0.000 1.000 0.000 0.000
## .GrpIDdatt2 0.003 0.056 0.053 0.957 0.003 0.003
## .GrpIDdatt3 0.004 0.056 0.079 0.937 0.004 0.004
## pc 0.000 0.000 0.000
## ae 0.000 0.000 0.000
## mw 0.000 0.000 0.000
## dsim 0.000 0.000 0.000
## datt 0.000 0.000 0.000
##
## Variances:
## Estimate Std.Err z-value P(>|z|) Std.lv Std.all
## .POPpc1 0.641 0.110 5.824 0.000 0.641 0.644
## .POPpc2 0.766 0.123 6.218 0.000 0.766 0.768
## .POPpc3 0.661 0.104 6.340 0.000 0.661 0.663
## .POPae1 0.482 0.074 6.489 0.000 0.482 0.484
## .POPae2 0.690 0.076 9.035 0.000 0.690 0.692
## .POPae3 0.356 0.086 4.138 0.000 0.356 0.357
## .POPmw1 0.593 0.161 3.686 0.000 0.593 0.594
## .POPmw2 0.762 0.146 5.228 0.000 0.762 0.763
## .POPmw3 0.933 0.078 11.923 0.000 0.933 0.936
## .GrpIDdsim1 0.202 0.028 7.211 0.000 0.202 0.203
## .GrpIDdsim2 0.334 0.070 4.787 0.000 0.334 0.335
## .GrpIDdsim3 0.213 0.031 6.971 0.000 0.213 0.213
## .GrpIDdatt1 0.229 0.039 5.803 0.000 0.229 0.230
## .GrpIDdatt2 0.187 0.033 5.635 0.000 0.187 0.188
## .GrpIDdatt3 0.196 0.030 6.541 0.000 0.196 0.196
## pc 1.000 1.000 1.000
## ae 1.000 1.000 1.000
## mw 1.000 1.000 1.000
## dsim 1.000 1.000 1.000
## datt 1.000 1.000 1.000
##
## R-Square:
## Estimate
## POPpc1 0.356
## POPpc2 0.232
## POPpc3 0.337
## POPae1 0.516
## POPae2 0.308
## POPae3 0.643
## POPmw1 0.406
## POPmw2 0.237
## POPmw3 0.064
## GrpIDdsim1 0.797
## GrpIDdsim2 0.665
## GrpIDdsim3 0.787
## GrpIDdatt1 0.770
## GrpIDdatt2 0.812
## GrpIDdatt3 0.804
semPaths(fit, "mod", "std", intercepts = F, edge.label.cex=1, rotation = 4, layout = "tree3")
round(reliability(fit),2)
## pc ae mw dsim datt total
## alpha 0.57 0.73 0.40 0.90 0.92 0.72
## omega 0.57 0.74 0.45 0.90 0.92 0.84
## omega2 0.57 0.74 0.45 0.90 0.92 0.84
## omega3 0.57 0.74 0.46 0.90 0.92 0.82
## avevar 0.31 0.49 0.24 0.75 0.80 0.52
US %>%
select(ant1,ant2,ant3,ant5,pop2,pop3, pop4,anes617,anes616,anes615,radact1,radact2,radact3,radact5,radact6) %>%
gather("Variable", "value") %>%
group_by(Variable) %>%
summarise(Mean=mean(value, na.rm=T),
SD=sd(value, na.rm=T),
min=min(value, na.rm=T),
max=max(value, na.rm=T),
'% Missing'=100*length(which(is.na(value)))/n()) %>%
kable(digits=2, format="pandoc", caption="Descriptive Statistics US")
Variable | Mean | SD | min | max | % Missing |
---|---|---|---|---|---|
anes615 | 2.11 | 1.69 | 1 | 7 | 0.00 |
anes616 | 2.16 | 1.73 | 1 | 7 | 0.00 |
anes617 | 2.05 | 1.67 | 1 | 7 | 0.00 |
ant1 | 5.63 | 1.41 | 1 | 7 | 39.01 |
ant2 | 5.53 | 1.40 | 1 | 7 | 39.47 |
ant3 | 5.22 | 1.44 | 1 | 7 | 38.85 |
ant5 | 4.58 | 1.66 | 1 | 7 | 38.39 |
pop2 | 5.72 | 1.26 | 1 | 7 | 40.40 |
pop3 | 5.18 | 1.63 | 1 | 7 | 41.18 |
pop4 | 5.03 | 1.53 | 1 | 7 | 40.87 |
radact1 | 1.92 | 1.48 | 1 | 7 | 38.24 |
radact2 | 2.49 | 1.71 | 1 | 7 | 38.08 |
radact3 | 2.22 | 1.59 | 1 | 7 | 35.60 |
radact5 | 2.26 | 1.56 | 1 | 7 | 37.00 |
radact6 | 2.96 | 1.82 | 1 | 7 | 39.32 |
US_fdp <- US %>% select(ant1,ant2,ant3,ant5,pop2,pop3, pop4,anes617,anes616,anes615,radact1,radact2,radact3,radact5,radact6)
s1dp <- ggplot(melt(US_fdp),aes(x=value)) + geom_density() + facet_wrap(~variable) + ggtitle("US: Density plots of the items used in Study 1")
## No id variables; using all as measure variables
DE1 %>%
select(POPpc3,POPpc1,POPae3,POPae1,POPmwv3,POPmwv1,alwVote,KWAoGov,ActSocPol,vp3,vp1) %>%
gather("Variable", "value") %>%
group_by(Variable) %>%
summarise(Mean=mean(value, na.rm=T),
SD=sd(value, na.rm=T),
min=min(value, na.rm=T),
max=max(value, na.rm=T),
'% Missing'=100*length(which(is.na(value)))/n()) %>%
kable(digits=2, format="pandoc", caption="Descriptive Statistics DE 1")
Variable | Mean | SD | min | max | % Missing |
---|---|---|---|---|---|
ActSocPol | 4.59 | 1.56 | 1 | 7 | 1.64 |
alwVote | 5.82 | 1.48 | 1 | 7 | 1.32 |
KWAoGov | 5.37 | 1.28 | 1 | 7 | 1.32 |
POPae1 | 4.27 | 1.60 | 1 | 7 | 1.64 |
POPae3 | 3.43 | 1.55 | 1 | 7 | 1.97 |
POPmwv1 | 3.25 | 1.62 | 1 | 7 | 1.64 |
POPmwv3 | 2.61 | 1.62 | 1 | 7 | 1.97 |
POPpc1 | 3.64 | 1.54 | 1 | 7 | 1.97 |
POPpc3 | 2.51 | 1.55 | 1 | 7 | 1.32 |
vp1 | 2.33 | 1.71 | 1 | 7 | 1.97 |
vp3 | 2.93 | 1.74 | 1 | 7 | 1.97 |
DE1_fdp <- DE1 %>% select(POPpc3,POPpc1,POPae3,POPae1,POPmwv3,POPmwv1,alwVote,KWAoGov,ActSocPol,vp3,vp1)
s2dp <- ggplot(melt(DE1_fdp),aes(x=value)) + geom_density() + facet_wrap(~variable) + ggtitle("DE: Density plots of the items used in Study 2")
## No id variables; using all as measure variables
DE2 %>%
select(POPpc1,POPpc2,POPpc3,POPae1,POPae2,POPae3,POPmw1,POPmw2,POPmw3,GrpIDdsim1,GrpIDdsim2,GrpIDdsim3,GrpIDdatt1,GrpIDdatt2,GrpIDdatt3) %>%
gather("Variable", "value") %>%
group_by(Variable) %>%
summarise(Mean=mean(value, na.rm=T),
SD=sd(value, na.rm=T),
min=min(value, na.rm=T),
max=max(value, na.rm=T),
'% Missing'=100*length(which(is.na(value)))/n()) %>%
kable(digits=2, format="pandoc", caption="Descriptive Statistics DE2")
Variable | Mean | SD | min | max | % Missing |
---|---|---|---|---|---|
GrpIDdatt1 | 3.48 | 1.33 | 1 | 5 | 4.48 |
GrpIDdatt2 | 3.20 | 1.30 | 1 | 5 | 5.07 |
GrpIDdatt3 | 3.15 | 1.35 | 1 | 5 | 5.07 |
GrpIDdsim1 | 3.14 | 1.22 | 1 | 5 | 4.78 |
GrpIDdsim2 | 3.35 | 1.16 | 1 | 5 | 4.78 |
GrpIDdsim3 | 3.27 | 1.19 | 1 | 5 | 4.78 |
POPae1 | 4.27 | 1.55 | 1 | 7 | 0.90 |
POPae2 | 3.72 | 1.21 | 1 | 7 | 1.49 |
POPae3 | 3.54 | 1.58 | 1 | 7 | 0.60 |
POPmw1 | 3.14 | 1.59 | 1 | 7 | 1.79 |
POPmw2 | 2.54 | 1.47 | 1 | 7 | 2.09 |
POPmw3 | 3.31 | 1.60 | 1 | 7 | 2.09 |
POPpc1 | 6.07 | 1.00 | 2 | 7 | 0.90 |
POPpc2 | 5.91 | 1.36 | 1 | 7 | 0.60 |
POPpc3 | 5.09 | 1.33 | 1 | 7 | 0.60 |
DE2_fdp <- DE2 %>% select(POPpc1,POPpc2,POPpc3,POPae1,POPae2,POPae3,POPmw1,POPmw2,POPmw3,GrpIDdsim1,GrpIDdsim2,GrpIDdsim3,GrpIDdatt1,GrpIDdatt2,GrpIDdatt3)
s3dp <- ggplot(melt(DE2_fdp),aes(x=value)) + geom_density() + facet_wrap(~variable) + ggtitle("DE: Density plots of the items used in Study 3")
## No id variables; using all as measure variables
gridExtra::grid.arrange(s1dp,s2dp,s3dp, nrow=2, ncol=2)
## Warning: Removed 3013 rows containing non-finite values (stat_density).
## Warning: Removed 57 rows containing non-finite values (stat_density).
## Warning: Removed 134 rows containing non-finite values (stat_density).
table(DE1$POlr)
##
## 1 2 3 4 5 6 7 8
## 19 48 109 53 36 20 10 4
DE1$POlr <- factor(DE1$POlr,
levels = c(1,2,3,4,5,6,7,8),
labels = c("Left","2","3", "4","5","6","7","Right"))
DE1 %>% select(POlr) %>% drop_na() %>% ggplot(., aes(x=POlr)) +
geom_bar(aes(y = (..count..)),fill="grey", alpha=0.6) +
geom_text(aes(y = (..count..) ,label = ifelse((..count..)==0,"",scales::percent((..count..)/sum(..count..)))), stat="count",colour="black") +
theme_bw() +
xlab("Self-Report Political Orientation in %") +
ylab("Frequency") +
labs(title="Political orientation of the German university students in study 2")
table(DE2$PolOrLR)
##
## 1 2 3 4 5 6 7
## 25 57 117 57 41 25 7
DE2$PolOrLR <- factor(DE2$PolOrLR,
levels = c(1,2,3,4,5,6,7),
labels = c("Left","2","3", "4","5","6","Right"))
DE2 %>% select(PolOrLR) %>% drop_na() %>% ggplot(., aes(x=PolOrLR)) +
geom_bar(aes(y = (..count..)),fill="grey", alpha=0.6) +
geom_text(aes(y = (..count..) ,label = ifelse((..count..)==0,"",scales::percent((..count..)/sum(..count..)))), stat="count",colour="black") +
theme_bw() +
xlab("Self-Report Political Orientation in %") +
ylab("Frequency") +
labs(title="Political orientation of the German university students in study 3")