stability_sh: Structural stability of a VAR(p)

View source: R/stability_sh.R

stability_shR Documentation

Structural stability of a VAR(p)

Description

Computes empirical fluctuation processes for VAR estimates. Utilizes strucchange::efp() for the VAR estimates of each time series variable.

Usage

stability_sh(
  x,
  type = c("OLS-CUSUM", "Rec-CUSUM", "Rec-MOSUM", "OLS-MOSUM", "RE", "ME", "Score-CUSUM",
    "Score-MOSUM", "fluctuation"),
  h = 0.15,
  dynamic = FALSE,
  rescale = TRUE,
  ...
)

Arguments

x

Object of class "varshrinkest"

type, h, dynamic, rescale, ...

Other arguments to strucchange::efp()

Details

A variant of vars::stability() for an object of class "varshrinkest".

Value

A list with class attribute "varstabil" which contains the following elements: stability, endog, K. The stability is a list of strucchange::efp() outputs.

See Also

stability

Examples

data(Canada, package = "vars")
y <- diff(Canada)
estim <- VARshrink(y, p = 2, type = "const", method = "ridge")
stabil <- stability_sh(estim)
plot(stabil)

VARshrink documentation built on Jan. 10, 2026, 1:06 a.m.