Skip to contents

Computes standardized estimates of model parameters for various types of modsem objects.

Usage

standardized_estimates(object, ...)

# S3 method for class 'lavaan'
standardized_estimates(
  object,
  monte.carlo = FALSE,
  mc.reps = 10000,
  tolerance.zero = 1e-10,
  ...
)

# S3 method for class 'modsem_da'
standardized_estimates(
  object,
  monte.carlo = FALSE,
  mc.reps = 10000,
  tolerance.zero = 1e-10,
  ...
)

# S3 method for class 'modsem_pi'
standardized_estimates(
  object,
  correction = FALSE,
  std.errors = c("rescale", "delta", "monte.carlo"),
  mc.reps = 10000,
  colon.pi = FALSE,
  ...
)

Arguments

object

An object of class modsem_da, modsem_mplus, modsem_pi, or a parameter table (parTable) of class data.frame.

...

Additional arguments passed on to lavaan::standardizedSolution().

monte.carlo

Logical. If TRUE, use Monte Carlo simulation to estimate standard errors; if FALSE, use the delta method (default).

mc.reps

Integer. Number of Monte Carlo replications to use if std.errors = "monte.carlo".

tolerance.zero

Threshold below which standard errors are set to NA.

correction

Logical. Whether to apply a correction to the standardized estimates of the interaction term. By default, FALSE, which standardizes the interaction term such that \(\sigma^2(XZ) = 1\), consistent with lavaan's treatment of latent interactions. This is usually wrong, as it does not account for the fact that the interaction term is a product of two variables, which means that the variance of the interaction term of standardized variables (usually) is not equal to 1.

Hence the scale of the interaction effect changes, such that the standardized interaction term does not correspond to one (standardized) unit change in the moderating variables. If TRUE a correction is applied, by computing the interaction term \(b_3 = \frac{B_3 \sigma(X) \sigma(Z)}{\sigma(Y)}\) (where \(B_3\) is the unstandardized coefficient for the interaction term), and solving for \(\sigma(XZ)\), which is used to correct the variance of the interaction term, and its covariances.

std.errors

Character string indicating the method used to compute standard errors when correction = TRUE. Options include:

"rescale"

Simply rescales the standard errors. Fastest option.

"delta"

Uses the delta method to approximate standard errors.

"monte.carlo"

Uses Monte Carlo simulation to estimate standard errors.

Ignored if correction = FALSE.

colon.pi

Logical. If TRUE, the interaction terms in the output will be will be formatted using : to seperate the elements in the interaction term. Default is FALSE, using the default formatting from lavaan. Only relevant if std.errors != "rescale" and correction == TRUE.

Value

A data.frame with standardized estimates in the est column.

Details

Standard errors can either be calculated using the delta method, or a monte.carlo simulation (monte.carlo is not available for modsem_pi objects if correction == FALSE.). NOTE that the standard errors of the standardized paramters change the assumptions of the model, and will in most cases yield different z and p-values, compared to the unstandardized solution. In almost all cases, significance testing should be based on the unstandardized solution. Since, the standardization process changes the model assumptions, it also changes what the p-statistics measure. I.e., the test statistics for the standardized and unstandardized solutions belong to different sets of hypothesis, which are not exactly equivalent to each other.

For modsem_da and modsem_mplus objects, the interaction term is not a formal variable in the model and therefore lacks a defined variance. Under assumptions of normality and zero-mean variables, the interaction variance is estimated as: $$var(xz) = var(x) * var(z) + cov(x, z)^2$$ This means the standardized estimate for the interaction differs from approaches like lavaan, which treats the interaction as a latent variable with unit variance.

For modsem_pi objects, the interaction term is standardized by default assuming var(xz) = 1, but this can be overridden using the correction argument.

NOTE: Standardized estimates are always placed in the est column, not est.std, regardless of model type.

Methods (by class)

  • standardized_estimates(lavaan): Method for lavaan objects

  • standardized_estimates(modsem_da): Method for modsem_da objects

  • standardized_estimates(modsem_pi): Method for modsem_pi objects

Examples

m1 <- '
  # Outer Model
  X =~ x1 + x2 + x3
  Z =~ z1 + z2 + z3
  Y =~ y1 + y2 + y3

  # Inner Model
  Y ~ X + Z + X:Z
'
# Double centering approach
est_dca <- modsem(m1, oneInt)

std1 <- standardized_estimates(est_dca) # no correction
summarize_partable(std1)
#> modsem (version 1.0.11)
#> 
#>   Number of model parameters                         64
#>   Number of latent variables                          4
#>   Number of observed variables                       18
#>  
#> Latent Variables:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>   X =~          
#>     x1              0.927      0.005  197.805    0.000
#>     x2              0.892      0.006  156.888    0.000
#>     x3              0.914      0.005  180.631    0.000
#>   Z =~          
#>     z1              0.926      0.005  197.375    0.000
#>     z2              0.899      0.005  164.838    0.000
#>     z3              0.913      0.005  180.409    0.000
#>   Y =~          
#>     y1              0.969      0.002  493.285    0.000
#>     y2              0.955      0.002  390.119    0.000
#>     y3              0.962      0.002  435.067    0.000
#>   XZ =~         
#>     x1z1            0.878      0.007  129.129    0.000
#>     x2z1            0.836      0.008  105.776    0.000
#>     x3z1            0.843      0.008  108.821    0.000
#>     x1z2            0.833      0.008  102.749    0.000
#>     x2z2            0.804      0.009   90.666    0.000
#>     x3z2            0.812      0.009   93.853    0.000
#>     x1z3            0.867      0.007  121.949    0.000
#>     x2z3            0.829      0.008  102.106    0.000
#>     x3z3            0.826      0.008  100.718    0.000
#> 
#> Regressions:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>   Y ~           
#>     X               0.424      0.016   26.787    0.000
#>     Z               0.358      0.016   22.372    0.000
#>     XZ              0.455      0.016   28.971    0.000
#> 
#> Covariances:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>  .x1z1 ~~       
#>    .x1z2            0.384      0.018   21.659    0.000
#>    .x1z3            0.393      0.019   20.928    0.000
#>    .x2z1            0.415      0.017   24.499    0.000
#>    .x3z1            0.440      0.017   25.573    0.000
#>  .x1z2 ~~       
#>    .x1z3            0.367      0.018   20.929    0.000
#>    .x2z2            0.486      0.014   33.698    0.000
#>    .x3z2            0.520      0.014   36.545    0.000
#>  .x1z3 ~~       
#>    .x2z3            0.450      0.016   28.177    0.000
#>    .x3z3            0.474      0.016   29.999    0.000
#>  .x2z1 ~~       
#>    .x2z2            0.510      0.014   35.404    0.000
#>    .x2z3            0.542      0.014   38.238    0.000
#>    .x3z1            0.370      0.016   22.694    0.000
#>  .x2z2 ~~       
#>    .x2z3            0.486      0.015   33.189    0.000
#>    .x3z2            0.456      0.014   31.605    0.000
#>  .x2z3 ~~       
#>    .x3z3            0.404      0.015   26.242    0.000
#>  .x3z1 ~~       
#>    .x3z2            0.464      0.015   30.577    0.000
#>    .x3z3            0.507      0.015   34.430    0.000
#>  .x3z2 ~~       
#>    .x3z3            0.464      0.015   31.361    0.000
#>   X ~~          
#>     Z               0.201      0.023    8.786    0.000
#>     XZ              0.015      0.024    0.628    0.530
#>   Z ~~          
#>     XZ              0.060      0.024    2.462    0.014
#> 
#> Variances:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>    .x1              0.140      0.009   16.115    0.000
#>    .x2              0.204      0.010   20.047    0.000
#>    .x3              0.165      0.009   17.875    0.000
#>    .z1              0.142      0.009   16.321    0.000
#>    .z2              0.191      0.010   19.481    0.000
#>    .z3              0.167      0.009   18.042    0.000
#>    .y1              0.060      0.004   15.807    0.000
#>    .y2              0.089      0.005   18.988    0.000
#>    .y3              0.075      0.004   17.723    0.000
#>    .x1z1            0.229      0.012   19.190    0.000
#>    .x2z1            0.301      0.013   22.788    0.000
#>    .x3z1            0.289      0.013   22.109    0.000
#>    .x1z2            0.306      0.014   22.696    0.000
#>    .x2z2            0.353      0.014   24.786    0.000
#>    .x3z2            0.341      0.014   24.264    0.000
#>    .x1z3            0.249      0.012   20.178    0.000
#>    .x2z3            0.313      0.013   23.291    0.000
#>    .x3z3            0.317      0.014   23.421    0.000
#>     X               1.000      0.000                  
#>     Z               1.000      0.000                  
#>    .Y               0.398      0.016   25.401    0.000
#>     XZ              1.000      0.000                  
#> 

std2 <- standardized_estimates(est_dca, correction = TRUE) # apply correction
summarize_partable(std2)
#> modsem (version 1.0.11)
#> 
#>   Number of model parameters                         64
#>   Number of latent variables                          4
#>   Number of observed variables                       18
#>  
#> Latent Variables:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>   X =~          
#>     x1              0.927      0.005  197.805    0.000
#>     x2              0.892      0.006  156.888    0.000
#>     x3              0.914      0.005  180.631    0.000
#>   Z =~          
#>     z1              0.926      0.005  197.375    0.000
#>     z2              0.899      0.005  164.838    0.000
#>     z3              0.913      0.005  180.409    0.000
#>   Y =~          
#>     y1              0.969      0.002  493.285    0.000
#>     y2              0.955      0.002  390.119    0.000
#>     y3              0.962      0.002  435.067    0.000
#>   XZ =~         
#>     x1z1            0.878      0.007  129.129    0.000
#>     x2z1            0.836      0.008  105.776    0.000
#>     x3z1            0.843      0.008  108.821    0.000
#>     x1z2            0.833      0.008  102.749    0.000
#>     x2z2            0.804      0.009   90.666    0.000
#>     x3z2            0.812      0.009   93.853    0.000
#>     x1z3            0.867      0.007  121.949    0.000
#>     x2z3            0.829      0.008  102.106    0.000
#>     x3z3            0.826      0.008  100.718    0.000
#> 
#> Regressions:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>   Y ~           
#>     X               0.424      0.016   26.787    0.000
#>     Z               0.358      0.016   22.372    0.000
#>     XZ              0.444      0.015   28.971    0.000
#> 
#> Covariances:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>  .x1z1 ~~       
#>    .x1z2            0.384      0.018   21.659    0.000
#>    .x1z3            0.393      0.019   20.928    0.000
#>    .x2z1            0.415      0.017   24.499    0.000
#>    .x3z1            0.440      0.017   25.573    0.000
#>  .x1z2 ~~       
#>    .x1z3            0.367      0.018   20.929    0.000
#>    .x2z2            0.486      0.014   33.698    0.000
#>    .x3z2            0.520      0.014   36.545    0.000
#>  .x1z3 ~~       
#>    .x2z3            0.450      0.016   28.177    0.000
#>    .x3z3            0.474      0.016   29.999    0.000
#>  .x2z1 ~~       
#>    .x2z2            0.510      0.014   35.404    0.000
#>    .x2z3            0.542      0.014   38.238    0.000
#>    .x3z1            0.370      0.016   22.694    0.000
#>  .x2z2 ~~       
#>    .x2z3            0.486      0.015   33.189    0.000
#>    .x3z2            0.456      0.014   31.605    0.000
#>  .x2z3 ~~       
#>    .x3z3            0.404      0.015   26.242    0.000
#>  .x3z1 ~~       
#>    .x3z2            0.464      0.015   30.577    0.000
#>    .x3z3            0.507      0.015   34.430    0.000
#>  .x3z2 ~~       
#>    .x3z3            0.464      0.015   31.361    0.000
#>   X ~~          
#>     Z               0.201      0.023    8.786    0.000
#>     XZ              0.016      0.025    0.628    0.530
#>   Z ~~          
#>     XZ              0.062      0.025    2.462    0.014
#> 
#> Variances:
#>                  Estimate  Std.Error  z.value  P(>|z|)
#>    .x1              0.140      0.009   16.115    0.000
#>    .x2              0.204      0.010   20.047    0.000
#>    .x3              0.165      0.009   17.875    0.000
#>    .z1              0.142      0.009   16.321    0.000
#>    .z2              0.191      0.010   19.481    0.000
#>    .z3              0.167      0.009   18.042    0.000
#>    .y1              0.060      0.004   15.807    0.000
#>    .y2              0.089      0.005   18.988    0.000
#>    .y3              0.075      0.004   17.723    0.000
#>    .x1z1            0.229      0.012   19.190    0.000
#>    .x2z1            0.301      0.013   22.788    0.000
#>    .x3z1            0.289      0.013   22.109    0.000
#>    .x1z2            0.306      0.014   22.696    0.000
#>    .x2z2            0.353      0.014   24.786    0.000
#>    .x3z2            0.341      0.014   24.264    0.000
#>    .x1z3            0.249      0.012   20.178    0.000
#>    .x2z3            0.313      0.013   23.291    0.000
#>    .x3z3            0.317      0.014   23.421    0.000
#>     X               1.000      0.000                  
#>     Z               1.000      0.000                  
#>    .Y               0.398      0.016   25.401    0.000
#>     XZ              1.049      0.000                  
#> 

# \dontrun{
est_lms <- modsem(m1, oneInt, method = "lms")
standardized_estimates(est_lms) # correction not relevant for lms
#>    lhs op rhs label   est std.error z.value p.value ci.lower ci.upper
#> 1    X =~  x1       0.927     0.004 211.281       0    0.918    0.935
#> 2    X =~  x2       0.891     0.005 166.759       0    0.881    0.902
#> 3    X =~  x3       0.912     0.005 191.406       0    0.902    0.921
#> 4    Z =~  z1       0.927     0.005 201.872       0    0.918    0.936
#> 5    Z =~  z2       0.898     0.005 166.700       0    0.888    0.909
#> 6    Z =~  z3       0.913     0.005 182.603       0    0.903    0.922
#> 7    Y =~  y1       0.969     0.002 471.554       0    0.965    0.973
#> 8    Y =~  y2       0.954     0.003 372.957       0    0.949    0.959
#> 9    Y =~  y3       0.961     0.002 411.036       0    0.956    0.965
#> 10   Y  ~   X       0.425     0.017  24.747       0    0.392    0.459
#> 11   Y  ~   Z       0.369     0.018  20.723       0    0.334    0.403
#> 12   Y  ~ X:Z       0.455     0.017  27.278       0    0.422    0.488
#> 13  x1 ~~  x1       0.142     0.008  17.631       0    0.126    0.157
#> 14  x2 ~~  x2       0.206     0.009  21.703       0    0.187    0.225
#> 15  x3 ~~  x3       0.169     0.009  19.438       0    0.152    0.186
#> 16  z1 ~~  z1       0.141     0.009  16.513       0    0.124    0.157
#> 17  z2 ~~  z2       0.193     0.010  19.707       0    0.174    0.212
#> 18  z3 ~~  z3       0.167     0.009  18.378       0    0.149    0.185
#> 19  y1 ~~  y1       0.062     0.004  16.003       0    0.054    0.069
#> 20  y2 ~~  y2       0.091     0.005  18.910       0    0.081    0.100
#> 21  y3 ~~  y3       0.077     0.004  17.987       0    0.069    0.085
#> 22   X ~~   X       1.000        NA      NA      NA       NA       NA
#> 23   X ~~   Z       0.200     0.023   8.782       0    0.155    0.244
#> 24   Z ~~   Z       1.000        NA      NA      NA       NA       NA
#> 25   Y ~~   Y       0.405     0.016  25.039       0    0.374    0.437
#> 26 X:Z ~~ X:Z       1.040     0.053  19.777       0    0.937    1.143
#> 27   X ~~ X:Z       0.000        NA      NA      NA       NA       NA
#> 28   Z ~~ X:Z       0.000        NA      NA      NA       NA       NA
# }