Skip to contents

Return the confidence intervals of betas-select in the output of lav_betaselect().

Usage

# S3 method for class 'lav_betaselect'
confint(object, parm, level = 0.95, ...)

Arguments

object

The output of lav_betaselect().

parm

Ignored due to the complexity in the naming. The confidence intervals of all parameters are always returned.

level

The level of confidence. Ignored because the intervals should be formed when calling lav_betaselect().

...

Optional arguments. Ignored.

Value

A two-column matrix of the confidence intervals.

Details

The type of confidence intervals depends on the call to lav_betaselect(). This function does not recompute the confidence interval.

See also

Examples


library(lavaan)
mod <-
"
med ~ iv + mod + iv:mod
dv ~ med + iv
"
fit <- sem(mod,
           data_test_medmod,
           fixed.x = TRUE)
summary(fit)
#> lavaan 0.6-19 ended normally after 3 iterations
#> 
#>   Estimator                                         ML
#>   Optimization method                           NLMINB
#>   Number of model parameters                         7
#> 
#>   Number of observations                           200
#> 
#> Model Test User Model:
#>                                                       
#>   Test statistic                                 2.685
#>   Degrees of freedom                                 2
#>   P-value (Chi-square)                           0.261
#> 
#> Parameter Estimates:
#> 
#>   Standard errors                             Standard
#>   Information                                 Expected
#>   Information saturated (h1) model          Structured
#> 
#> Regressions:
#>                    Estimate   Std.Err  z-value  P(>|z|)
#>   med ~                                                
#>     iv                -6.339    0.997   -6.357    0.000
#>     mod               -3.903    0.622   -6.277    0.000
#>     iv:mod             0.286    0.039    7.248    0.000
#>   dv ~                                                 
#>     med                0.093    0.011    8.298    0.000
#>     iv                 0.229    0.039    5.917    0.000
#> 
#> Variances:
#>                    Estimate   Std.Err  z-value  P(>|z|)
#>    .med               61.851    6.185   10.000    0.000
#>    .dv                 2.104    0.210   10.000    0.000
#> 
fit_beta <- lav_betaselect(fit,
                           to_standardize = c("iv", "dv"))
confint(fit_beta)
#>                [,1] [,2]
#> med~iv           NA   NA
#> med~mod          NA   NA
#> med~iv:mod       NA   NA
#> dv~med           NA   NA
#> dv~iv            NA   NA
#> med~~med         NA   NA
#> dv~~dv           NA   NA
#> iv~~iv           NA   NA
#> iv~~mod          NA   NA
#> iv~~iv:mod       NA   NA
#> mod~~mod         NA   NA
#> mod~~iv:mod      NA   NA
#> iv:mod~~iv:mod   NA   NA