Skip to contents

Summarary Method for Multivariate or Univarate Regression

Usage

regression_summary(object, cred = 0.95, ...)

Arguments

object

An object of class estimate

cred

Numeric. The credible interval width for summarizing the posterior distributions (defaults to 0.95; must be between 0 and 1).

...

Currently ignored

Value

A list of length p including the summaries for each regression.

Examples

# \donttest{
# note: iter = 250 for demonstrative purposes

# data
Y <- bfi

Y <- subset(Y, select = c("A1", "A2", 
                          "gender", "education"))

fit_mv_ordinal <- estimate(Y, formula = ~ gender + as.factor(education),
                           type = "continuous",
                           iter = 250,
                           progress = TRUE)
#> BGGM: Posterior Sampling 
#> BGGM: Finished

regression_summary(fit_mv_ordinal)
#> BGGM: Bayesian Gaussian Graphical Models 
#> --- 
#> Type: continuous 
#> Formula: ~ gender + as.factor(education) 
#> --- 
#> Coefficients: 
#>  
#> A1 
#>                       Post.mean Post.sd Cred.lb Cred.ub
#> (Intercept)               1.065   0.137   0.814   1.330
#> gender                   -0.515   0.064  -0.644  -0.405
#> as.factor(education)2     0.127   0.134  -0.124   0.393
#> as.factor(education)3    -0.130   0.098  -0.314   0.093
#> as.factor(education)4    -0.422   0.119  -0.644  -0.192
#> as.factor(education)5    -0.552   0.107  -0.752  -0.343
#> --- 
#> A2 
#>                       Post.mean Post.sd Cred.lb Cred.ub
#> (Intercept)              -0.868   0.099  -1.060  -0.689
#> gender                    0.484   0.050   0.391   0.578
#> as.factor(education)2    -0.033   0.094  -0.229   0.149
#> as.factor(education)3     0.117   0.081  -0.036   0.269
#> as.factor(education)4    -0.038   0.097  -0.236   0.153
#> as.factor(education)5     0.080   0.086  -0.080   0.233
#> --- 
#> Residual Correlation Matrix: 
#>        A1     A2
#> A1  1.000 -0.314
#> A2 -0.314  1.000
#> --- 
# }