specify_prior_bsvar {bsvars} R Documentation

## R6 Class Representing PriorBSVAR

### Description

The class PriorBSVAR presents a prior specification for the homoskedastic bsvar model.

### Public fields

A

an NxK matrix, the mean of the normal prior distribution for the parameter matrix A.

A_V_inv

a KxK precision matrix of the normal prior distribution for each of the row of the parameter matrix A. This precision matrix is equation invariant.

B_V_inv

an NxN precision matrix of the generalised-normal prior distribution for the structural matrix B. This precision matrix is equation invariant.

B_nu

a positive integer greater of equal than N, a shape parameter of the generalised-normal prior distribution for the structural matrix B.

hyper_nu

a positive scalar, the shape parameter of the inverted-gamma 2 prior distribution for the two overall shrinkage parameters for matrices B and A.

hyper_a

a positive scalar, the shape parameter of the gamma prior for the two overall shrinkage parameters.

hyper_V

a positive scalar, the shape parameter of the inverted-gamma 2 for the level 3 hierarchy of shrinkage parameters.

hyper_S

a positive scalar, the scale parameter of the inverted-gamma 2 for the level 3 hierarchy of shrinkage parameters.

### Methods

#### Method new()

Create a new prior specification PriorBSVAR.

##### Examples
# a prior for 3-variable example with four lags
prior = specify_prior_bsvar$new(N = 3, p = 4) prior$get_prior() # show the prior as list



#### Method clone()

The objects of this class are cloneable with this method.

specify_prior_bsvar$clone(deep = FALSE) ##### Arguments deep Whether to make a deep clone. ### Examples prior = specify_prior_bsvar$new(N = 3, p = 1)  # a prior for 3-variable example with one lag
prior$A # show autoregressive prior mean ## ------------------------------------------------ ## Method specify_prior_bsvar$new
## ------------------------------------------------

# a prior for 3-variable example with one lag and stationary data
prior = specify_prior_bsvar$new(N = 3, p = 1, stationary = rep(TRUE, 3)) prior$A # show autoregressive prior mean

## ------------------------------------------------
## Method specify_prior_bsvar$get_prior ## ------------------------------------------------ # a prior for 3-variable example with four lags prior = specify_prior_bsvar$new(N = 3, p = 4)
prior\$get_prior() # show the prior as list



[Package bsvars version 1.0.0 Index]