Get Centered Interaction Term Estimates
centered_estimates.RdComputes centered estimates of model parameters. This is relevant when there is an
 interaction term in the model, as the simple main effects depend upon the mean structure
 of the structural model. Currenlty only available for
 modsem_da and lavaan object.
 It is not relevant for the PI approaches (excluding the "pind" method, which is not recommended),
 since the indicators are centered before computing the product terms.
 The centering can be applied to observed variable interactions in lavaan models
 and latent interactions estimated using the sam function.
Usage
centered_estimates(object, ...)
# S3 method for class 'lavaan'
centered_estimates(
  object,
  monte.carlo = FALSE,
  mc.reps = 10000,
  tolerance.zero = 1e-10,
  ...
)
# S3 method for class 'modsem_da'
centered_estimates(
  object,
  monte.carlo = FALSE,
  mc.reps = 10000,
  tolerance.zero = 1e-10,
  ...
)Arguments
- object
 An object of class
modsem_da- ...
 Additional arguments passed to underlying methods. See specific method documentation for supported arguments, including:
- monte.carlo
 Logical. If
TRUE, use Monte Carlo simulation to estimate standard errors; ifFALSE, use the delta method (default).- mc.reps
 Number of Monte Carlo repetitions. Default is 10000.
- tolerance.zero
 Threshold below which standard errors are set to
NA.
Methods (by class)
centered_estimates(lavaan): Method forlavaanobjectscentered_estimates(modsem_da): Method formodsem_daobjects
Examples
m1 <- '
  # Outer Model
  X =~ x1 + x2 + x3
  Z =~ z1 + z2 + z3
  Y =~ y1 + y2 + y3
  # Inner Model
  Y ~ X + Z + X:Z
'
# \dontrun{
est_lms <- modsem(m1, oneInt, method = "lms")
centered_estimates(est_lms)
#>    lhs op rhs label group   est std.error z.value p.value ci.lower ci.upper
#> 1    X =~  x1           1 1.000        NA      NA      NA       NA       NA
#> 2    X =~  x2           1 0.803     0.013  63.817       0    0.779    0.828
#> 3    X =~  x3           1 0.914     0.014  67.615       0    0.887    0.940
#> 4    Z =~  z1           1 1.000        NA      NA      NA       NA       NA
#> 5    Z =~  z2           1 0.810     0.012  65.088       0    0.786    0.835
#> 6    Z =~  z3           1 0.881     0.013  67.616       0    0.856    0.907
#> 7    Y =~  y1           1 1.000        NA      NA      NA       NA       NA
#> 8    Y =~  y2           1 0.798     0.007 107.548       0    0.784    0.813
#> 9    Y =~  y3           1 0.899     0.008 112.583       0    0.884    0.915
#> 10   Y  ~   X           1 0.672     0.031  21.650       0    0.611    0.733
#> 11   Y  ~   Z           1 0.568     0.030  18.690       0    0.508    0.628
#> 12   Y  ~ X:Z           1 0.718     0.028  25.828       0    0.664    0.773
#> 13  x1 ~~  x1           1 0.158     0.009  18.170       0    0.141    0.175
#> 14  x2 ~~  x2           1 0.162     0.007  23.160       0    0.148    0.176
#> 15  x3 ~~  x3           1 0.164     0.008  20.758       0    0.149    0.180
#> 16  z1 ~~  z1           1 0.167     0.009  18.505       0    0.149    0.184
#> 17  z2 ~~  z2           1 0.160     0.007  22.680       0    0.146    0.173
#> 18  z3 ~~  z3           1 0.158     0.008  20.778       0    0.143    0.173
#> 19  y1 ~~  y1           1 0.160     0.009  18.011       0    0.142    0.177
#> 20  y2 ~~  y2           1 0.154     0.007  22.687       0    0.141    0.168
#> 21  y3 ~~  y3           1 0.164     0.008  20.682       0    0.148    0.179
#> 22   X ~~   X           1 0.981     0.036  26.975       0    0.910    1.052
#> 23   X ~~   Z           1 0.200     0.024   8.242       0    0.152    0.247
#> 24   X ~~ X:Z           1 0.000        NA      NA      NA       NA       NA
#> 25   Z ~~   Z           1 1.017     0.038  26.935       0    0.943    1.091
#> 26   Z ~~ X:Z           1 0.000        NA      NA      NA       NA       NA
#> 27   Y ~~   Y           1 0.980     0.038  25.932       0    0.906    1.054
#> 28 X:Z ~~ X:Z           1 1.038        NA      NA      NA       NA       NA
# }