
Provides posterior summary of Structural VAR with t-distributed shocks estimation
Source:R/summary.R
summary.PosteriorBSVART.Rd
Provides posterior mean, standard deviations, as well as 5 and 95 percentiles of the parameters: the structural matrix \(B\), autoregressive parameters \(A\), hyper-parameters, and Student-t degrees-of-freedom parameter \(\nu\).
Usage
# S3 method for class 'PosteriorBSVART'
summary(object, ...)
Arguments
- object
an object of class PosteriorBSVART obtained using the
estimate()
function applied to homoskedastic Bayesian Structural VAR model specification set by functionspecify_bsvar$new()
containing draws from the posterior distribution of the parameters.- ...
additional arguments affecting the summary produced.
Value
A list reporting the posterior mean, standard deviations, as well as 5 and 95 percentiles of the parameters: the structural matrix \(B\), autoregressive parameters \(A\), hyper-parameters, and Student-t degrees-of-freedom parameter \(\nu\).
Author
Tomasz Woźniak wozniak.tom@pm.me
Examples
# upload data
data(us_fiscal_lsuw)
# specify the model and set seed
set.seed(123)
specification = specify_bsvar_t$new(us_fiscal_lsuw)
#> The identification is set to the default option of lower-triangular structural matrix.
# run the burn-in
burn_in = estimate(specification, 10)
#> **************************************************|
#> bsvars: Bayesian Structural Vector Autoregressions|
#> **************************************************|
#> Gibbs sampler for the SVAR model |
#> with t-distributed structural skocks |
#> **************************************************|
#> Progress of the MCMC simulation for 10 draws
#> Every draw is saved via MCMC thinning
#> Press Esc to interrupt the computations
#> **************************************************|
# estimate the model
posterior = estimate(burn_in, 20)
#> **************************************************|
#> bsvars: Bayesian Structural Vector Autoregressions|
#> **************************************************|
#> Gibbs sampler for the SVAR model |
#> with t-distributed structural skocks |
#> **************************************************|
#> Progress of the MCMC simulation for 20 draws
#> Every draw is saved via MCMC thinning
#> Press Esc to interrupt the computations
#> **************************************************|
summary(posterior)
#> **************************************************|
#> bsvars: Bayesian Structural Vector Autoregressions|
#> **************************************************|
#> Posterior summary of the parameters |
#> **************************************************|
#> $B
#> $B$equation1
#> mean sd 5% quantile 95% quantile
#> B[1,1] 5.683473 0.270597 5.305968 6.00139
#>
#> $B$equation2
#> mean sd 5% quantile 95% quantile
#> B[2,1] 16.60781 2.285398 13.97238 20.53425
#> B[2,2] 51.58255 3.553366 46.76183 56.95305
#>
#> $B$equation3
#> mean sd 5% quantile 95% quantile
#> B[3,1] -56.11701 2.584825 -59.857149 -53.06085
#> B[3,2] 11.36434 2.821094 6.887335 15.62287
#> B[3,3] 69.24383 3.266620 64.327254 73.23511
#>
#>
#> $A
#> $A$equation1
#> mean sd 5% quantile 95% quantile
#> lag1_var1 1.44333116 0.01763852 1.42279587 1.4759796
#> lag1_var2 -0.14176708 0.02522578 -0.17551781 -0.1049694
#> lag1_var3 -0.33758180 0.03316838 -0.39636935 -0.3003929
#> const 0.09625648 0.13516819 -0.06067087 0.3223017
#>
#> $A$equation2
#> mean sd 5% quantile 95% quantile
#> lag1_var1 -0.1723648 0.01500039 -0.1950080 -0.1468958
#> lag1_var2 1.0179641 0.01374906 0.9968141 1.0373253
#> lag1_var3 0.1485959 0.01362534 0.1335286 0.1701090
#> const -0.2823277 0.08249560 -0.3949441 -0.1641334
#>
#> $A$equation3
#> mean sd 5% quantile 95% quantile
#> lag1_var1 0.4175438 0.02066918 0.3956690 0.44983763
#> lag1_var2 -0.1188649 0.02833001 -0.1645518 -0.07965057
#> lag1_var3 0.6660893 0.01374631 0.6432788 0.68828124
#> const 0.1245590 0.11228241 -0.0352645 0.29256423
#>
#>
#> $hyper
#> $hyper$B
#> mean sd 5% quantile 95% quantile
#> B[1,]_shrinkage 404.9914 293.2989 107.4329 867.1980
#> B[2,]_shrinkage 706.7319 427.1349 250.1326 1353.5998
#> B[3,]_shrinkage 1036.5466 461.9636 502.3239 1888.6574
#> B[1,]_shrinkage_scale 3752.2937 2151.0982 1091.0831 7311.8121
#> B[2,]_shrinkage_scale 4732.4588 2442.1000 1437.0846 9323.6021
#> B[3,]_shrinkage_scale 5079.5538 2332.7047 1628.8525 8703.0604
#> B_global_scale 405.0931 179.0249 101.0425 634.0845
#>
#> $hyper$A
#> mean sd 5% quantile 95% quantile
#> A[1,]_shrinkage 0.5096583 0.3625476 0.2665960 1.0096442
#> A[2,]_shrinkage 0.3470133 0.1480129 0.1518203 0.5869494
#> A[3,]_shrinkage 0.4128128 0.2162187 0.1967992 0.8327323
#> A[1,]_shrinkage_scale 4.9415393 1.5862675 3.0978850 7.1957609
#> A[2,]_shrinkage_scale 4.5707284 1.2301488 2.9930029 6.4187707
#> A[3,]_shrinkage_scale 5.0105320 1.5121636 3.1038318 6.8492489
#> A_global_scale 0.5721111 0.1192033 0.4231608 0.7478832
#>
#>
#> $df
#> mean sd 5% quantile 95% quantile
#> 4.6373010 0.8939566 3.2099088 5.7832688
#>
# workflow with the pipe |>
############################################################
set.seed(123)
us_fiscal_lsuw |>
specify_bsvar_t$new() |>
estimate(S = 10) |>
estimate(S = 20) |>
summary()
#> The identification is set to the default option of lower-triangular structural matrix.
#> **************************************************|
#> bsvars: Bayesian Structural Vector Autoregressions|
#> **************************************************|
#> Gibbs sampler for the SVAR model |
#> with t-distributed structural skocks |
#> **************************************************|
#> Progress of the MCMC simulation for 10 draws
#> Every draw is saved via MCMC thinning
#> Press Esc to interrupt the computations
#> **************************************************|
#> **************************************************|
#> bsvars: Bayesian Structural Vector Autoregressions|
#> **************************************************|
#> Gibbs sampler for the SVAR model |
#> with t-distributed structural skocks |
#> **************************************************|
#> Progress of the MCMC simulation for 20 draws
#> Every draw is saved via MCMC thinning
#> Press Esc to interrupt the computations
#> **************************************************|
#> **************************************************|
#> bsvars: Bayesian Structural Vector Autoregressions|
#> **************************************************|
#> Posterior summary of the parameters |
#> **************************************************|
#> $B
#> $B$equation1
#> mean sd 5% quantile 95% quantile
#> B[1,1] 5.683473 0.270597 5.305968 6.00139
#>
#> $B$equation2
#> mean sd 5% quantile 95% quantile
#> B[2,1] 16.60781 2.285398 13.97238 20.53425
#> B[2,2] 51.58255 3.553366 46.76183 56.95305
#>
#> $B$equation3
#> mean sd 5% quantile 95% quantile
#> B[3,1] -56.11701 2.584825 -59.857149 -53.06085
#> B[3,2] 11.36434 2.821094 6.887335 15.62287
#> B[3,3] 69.24383 3.266620 64.327254 73.23511
#>
#>
#> $A
#> $A$equation1
#> mean sd 5% quantile 95% quantile
#> lag1_var1 1.44333116 0.01763852 1.42279587 1.4759796
#> lag1_var2 -0.14176708 0.02522578 -0.17551781 -0.1049694
#> lag1_var3 -0.33758180 0.03316838 -0.39636935 -0.3003929
#> const 0.09625648 0.13516819 -0.06067087 0.3223017
#>
#> $A$equation2
#> mean sd 5% quantile 95% quantile
#> lag1_var1 -0.1723648 0.01500039 -0.1950080 -0.1468958
#> lag1_var2 1.0179641 0.01374906 0.9968141 1.0373253
#> lag1_var3 0.1485959 0.01362534 0.1335286 0.1701090
#> const -0.2823277 0.08249560 -0.3949441 -0.1641334
#>
#> $A$equation3
#> mean sd 5% quantile 95% quantile
#> lag1_var1 0.4175438 0.02066918 0.3956690 0.44983763
#> lag1_var2 -0.1188649 0.02833001 -0.1645518 -0.07965057
#> lag1_var3 0.6660893 0.01374631 0.6432788 0.68828124
#> const 0.1245590 0.11228241 -0.0352645 0.29256423
#>
#>
#> $hyper
#> $hyper$B
#> mean sd 5% quantile 95% quantile
#> B[1,]_shrinkage 404.9914 293.2989 107.4329 867.1980
#> B[2,]_shrinkage 706.7319 427.1349 250.1326 1353.5998
#> B[3,]_shrinkage 1036.5466 461.9636 502.3239 1888.6574
#> B[1,]_shrinkage_scale 3752.2937 2151.0982 1091.0831 7311.8121
#> B[2,]_shrinkage_scale 4732.4588 2442.1000 1437.0846 9323.6021
#> B[3,]_shrinkage_scale 5079.5538 2332.7047 1628.8525 8703.0604
#> B_global_scale 405.0931 179.0249 101.0425 634.0845
#>
#> $hyper$A
#> mean sd 5% quantile 95% quantile
#> A[1,]_shrinkage 0.5096583 0.3625476 0.2665960 1.0096442
#> A[2,]_shrinkage 0.3470133 0.1480129 0.1518203 0.5869494
#> A[3,]_shrinkage 0.4128128 0.2162187 0.1967992 0.8327323
#> A[1,]_shrinkage_scale 4.9415393 1.5862675 3.0978850 7.1957609
#> A[2,]_shrinkage_scale 4.5707284 1.2301488 2.9930029 6.4187707
#> A[3,]_shrinkage_scale 5.0105320 1.5121636 3.1038318 6.8492489
#> A_global_scale 0.5721111 0.1192033 0.4231608 0.7478832
#>
#>
#> $df
#> mean sd 5% quantile 95% quantile
#> 4.6373010 0.8939566 3.2099088 5.7832688
#>