By analyzing time series, it is possible to observe significant changes in the behavior of observations that frequently characterize events. Events present themselves as anomalies, change points, or motifs. In the literature, there are several methods for detecting events. However, searching for a suitable time series method is a complex task, especially considering that the nature of events is often unknown. This work presents Harbinger, a framework for integrating and analyzing event detection methods. Harbinger contains several state-of-the-art methods described in Salles et al. (2020)
Harbinger
Harbinger is an R framework for time series event detection. It provides a unified interface for anomaly detection, change-point detection, motif discovery, discord discovery, transformations, plotting, online execution, and event-oriented evaluation.
Time-series event analysis is rarely a matter of calling one isolated function. In practice, the analyst needs to understand the signal, choose a suitable family of methods, inspect the result visually, and evaluate whether the detected events actually correspond to the phenomenon of interest. Harbinger supports this full learning and experimentation path with consistent method APIs and reusable experiment workflows.
Current package version in this repository: 2.1.707.
The stable version is available on CRAN:
https://CRAN.R-project.org/package=harbinger
install.packages("harbinger")
The development version is available on GitHub:
https://github.com/cefet-rj-dal/harbinger
library(devtools)
devtools::install_github("cefet-rj-dal/harbinger", force = TRUE, upgrade = "never")
Documentation and examples are available in the package site and in the repository:
The documentation is organized around two complementary entry points:
If you are new to harbinger, start with the tutorials. If you already
know the basic workflow, the thematic collections provide focused
examples by event type, data source, transformation, and execution mode.
The tutorials are part of the examples collection. They form a 10-part learning sequence covering first contact with the package, data inspection, plotting, baseline anomaly detection, residual-based detection, evaluation, change points, smoothing, symbolic transformations, and motif analysis.
The sequence is cumulative. It introduces event detection through small workflows before moving to richer event families and representations.
The examples collection includes thematic subcollections:
The snippet below uses the default harbinger() pipeline on a bundled
dataset. It is intentionally short so that a new reader can see the
minimum workflow before moving to the more didactic notebooks in
examples/.
library(harbinger)
# Load an example dataset with labeled anomalies
data(examples_anomalies)
# Create the default detector and run it on the series
model <- harbinger()
detection <- detect(model, examples_anomalies$simple$serie)
# Inspect only the detected events
subset(detection, event == TRUE)
The public course material includes a compact slide sequence that introduces Harbinger and demonstrates the main package workflows: overview, tutorial, general workflow, datasets, transformations, anomalies, change points, motifs, and custom extensions.
examples/slides/README.md.examples/videos/README.md.Please report bugs, questions, and feature requests at: