Reports whether the null hypothesis of a unit root is rejected against the alternative of explosive behavior, for each series in a dataset.
Usage
diagnostics(object, cv = NULL, ...)
# S3 method for class 'radf_obj'
diagnostics(object, cv = NULL, option = c("gsadf", "sadf"), sig_lvl = 95, ...)Arguments
- object
An object of class
obj.- cv
An object of class
cv.- ...
Further arguments passed to methods.
- option
Whether to apply the "gsadf" or "sadf" methodology (default = "gsadf").
- sig_lvl
Significance level, one of 90, 95 or 99, that decides whether a series counts as "positive" (rejects the null). It does not depend on the test statistic chosen with
option.
Value
A list with the series that reject the null hypothesis (positive) and the series that do not (negative), together with the significance level.
Details
diagnostics also stores a vector that takes the value 1 when there is a
period of explosive behavior and 0 otherwise.
Examples
# \donttest{
# The default `cv` is fetched from the shared critical-value store
# (network on first use); pass `cv = radf_mc_cv(nrow(sim_data))` to stay offline
rsim_data <- radf(sim_data)
diagnostics(rsim_data)
#> Using precomputed critical values for `cv`.
#>
#> ── Diagnostics (option = gsadf) ───────────────────────────────── Monte Carlo ──
#>
#> psy1: Rejects H0 at the 1% significance level
#> psy2: Rejects H0 at the 1% significance level
#> evans: Rejects H0 at the 1% significance level
#> div: Cannot reject H0
#> blan: Rejects H0 at the 1% significance level
#>
diagnostics(rsim_data, option = "sadf")
#> Using precomputed critical values for `cv`.
#>
#> ── Diagnostics (option = sadf) ────────────────────────────────── Monte Carlo ──
#>
#> psy1: Rejects H0 at the 1% significance level
#> psy2: Rejects H0 at the 1% significance level
#> evans: Rejects H0 at the 1% significance level
#> div: Rejects H0 at the 10% significance level
#> blan: Rejects H0 at the 1% significance level
#>
# Gate on the 90% critical value instead of the 95% default
diagnostics(rsim_data, sig_lvl = 90)
#> Using precomputed critical values for `cv`.
#>
#> ── Diagnostics (option = gsadf) ───────────────────────────────── Monte Carlo ──
#>
#> psy1: Rejects H0 at the 1% significance level
#> psy2: Rejects H0 at the 1% significance level
#> evans: Rejects H0 at the 1% significance level
#> div: Cannot reject H0
#> blan: Rejects H0 at the 1% significance level
#>
# }
