PandemicBreak#

class impulso.conjugate_volatility.PandemicBreak(*, is_time_varying=True, name='pandemic_break', start)[source]#

Bases: ConjugateVolatility

Lenza-Primiceri (2020) deterministic COVID-19 volatility break.

Three free outbreak scales at t*, t*+1, t*+2 (March-May 2020) inflate the residual covariance, after which volatility decays geometrically back toward its pre-pandemic level (j = t - t*):

s_t = 1                              for t < t*        (pre-pandemic)
s_t = s_march, s_april, s_may        at t*, t*+1, t*+2 (outbreak)
s_t = 1 + (s_may - 1) * rho**(j - 2) for t >= t*+3     (decay)

The forecast path continues the decay: step k (June 2020 onward, t*+3+k) uses 1 + (s_may - 1) * rho**(k + 1). Each outbreak scale carries a Pareto(1, 1) prior (support >= 1); rho carries a Beta prior with mode 0.8 and sd 0.2.

Parameters:
name#

Discriminator key (always “pandemic_break”).

Type:

Literal[‘pandemic_break’]

start#

Index of t* (March 2020) in the lag-trimmed in-sample data.

Type:

int

Expand for references to impulso.conjugate_volatility.PandemicBreak

Estimating a VAR after March 2020 / What this reproduction does and does not match

hyperparameter_priors()[source]#

1-D priors on the free volatility hyperparameters, keyed by name.

Return type:

dict[str, Prior1D]

log_scales(theta, T)[source]#

In-sample log-scale path log s_t of shape (T,) for hyperparameters theta.

Fed to impulso._conjugate.log_marginal_likelihood(log_scales=…).

Parameters:
Return type:

ndarray

model_config = {'frozen': True}#

Configuration for the model, should be a dictionary conforming to [ConfigDict][pydantic.config.ConfigDict].