plot.regimes: Plot Time Series Data with Detected Regime Stability

View source: R/plot.R

plot.regimesR Documentation

Plot Time Series Data with Detected Regime Stability

Description

Plot Time Series Data with Detected Regime Stability

Usage

## S3 method for class 'regimes'
plot(x, points = FALSE, ...)

Arguments

x

[regimes]
Output of detect_regimes().

points

[logical(1)]
Should a point be added for each observation? The points are colored by regime stability (default: FALSE).

...

Ignored.

Value

A ggplot object.

Examples

set.seed(123)
ts_data <- stats::arima.sim(list(order = c(1, 1, 0), ar = 0.6), n = 200)
regimes <- detect_regimes(
  data = ts_data,
  method = "threshold",
  sensitivity = "medium"
)
plot(regimes)


codyna documentation built on Jan. 16, 2026, 5:15 p.m.