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.057   0.130   0.806   1.297
#> gender                   -0.513   0.060  -0.628  -0.399
#> as.factor(education)2     0.131   0.118  -0.094   0.355
#> as.factor(education)3    -0.125   0.097  -0.316   0.044
#> as.factor(education)4    -0.419   0.107  -0.611  -0.199
#> as.factor(education)5    -0.545   0.113  -0.764  -0.355
#> --- 
#> A2 
#>                       Post.mean Post.sd Cred.lb Cred.ub
#> (Intercept)              -0.873   0.110  -1.068  -0.669
#> gender                    0.486   0.050   0.387   0.575
#> as.factor(education)2    -0.028   0.104  -0.231   0.153
#> as.factor(education)3     0.113   0.087  -0.057   0.276
#> as.factor(education)4    -0.042   0.097  -0.230   0.151
#> as.factor(education)5     0.085   0.096  -0.085   0.269
#> --- 
#> Residual Correlation Matrix: 
#>        A1     A2
#> A1  1.000 -0.313
#> A2 -0.313  1.000
#> --- 
# }