Skip to contents

The alarm log of a monitor

Usage

alarms(x, ...)

# S3 method for class 'ggcpt_monitor'
alarms(x, ...)

Arguments

x

A ggcpt_monitor object.

...

Ignored.

Value

A tibble with one row per alarm: time (the observation at which it fired, counted from the first one fed to the monitor), statistic and threshold.

Examples

set.seed(2026)
mon <- cpt_monitor("edetector", baseline = rnorm(100))
mon <- cpt_update(mon, c(rnorm(50), rnorm(50, 3)))
alarms(mon)
#> # A tibble: 1 × 3
#>    time statistic threshold
#>   <int>     <dbl>     <dbl>
#> 1    51      134.       100