Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

update_t_error

Single MCMC update to Student's t-distribution


Description

Samples the degrees of freedom parameter of standardized and homoskedastic t-distributed input variates. Marginal data augmentation (MDA) is applied, tau is the vector of auxiliary latent states. Depending on the prior specification, nu might not be updated, just tau.

Usage

update_t_error(
  homosked_data,
  tau,
  mean,
  sd,
  nu,
  prior_spec,
  do_tau_acceptance_rejection = TRUE
)

Arguments

homosked_data

de-meaned and homoskedastic observations

tau

the vector of the latent states used in MDA. Updated in place

mean

the vector of the conditional means // TODO update docs in R

sd

the vector of the conditional standard deviations

nu

parameter nu. The degrees of freedom for the t-distribution. Updated in place

prior_spec

prior specification object. See type_definitions.h

do_tau_acceptance_rejection

boolean. If TRUE, there is a correction for non-zero mean and non-unit sd, otherwise the proposal distribution is used

Details

The function samples tau and nu from the following hierarchical model: homosked_data_i = sqrt(tau_i) * (mean_i + sd_i * N(0, 1)) tau_i ~ InvGamma(.5*nu, .5*(nu-2)) Naming: The data is homoskedastic ex ante in the model, mean_i and sd_i are conditional on some other parameter in the model. The prior on tau corresponds to a standardized t-distributed heavy tail on the data.

See Also


stochvol

Efficient Bayesian Inference for Stochastic Volatility (SV) Models

v3.0.4
GPL (>= 2)
Authors
Darjus Hosszejni [aut, cre] (<https://orcid.org/0000-0002-3803-691X>), Gregor Kastner [aut] (<https://orcid.org/0000-0002-8237-8271>)
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.