har_stream_eval: Streaming evaluation for online detection

View source: R/har_stream_eval.R

har_stream_evalR Documentation

Streaming evaluation for online detection

Description

Evaluates structured online traces produced by har_online_session(). This evaluator complements har_eval() by computing the metrics introduced in the Nexus paper, namely Detection Probability (DP) and Detection Lag (DL), while also exposing conventional end-of-run classification metrics when labels are available.

Usage

har_stream_eval()

Value

A har_stream_eval object.

Examples

source <- har_source_simulated(c(1, 1, 1, 10, 1, 1))
session <- har_online_session(
  source = source,
  detector = hcp_page_hinkley(min_instances = 3, threshold = 1),
  warmup_size = 3,
  batch_size = 1
)
session <- daltoolbox::fit(session)
session <- run_online(session)
trace <- collect_trace(session)
daltoolbox::evaluate(har_stream_eval(), trace)

harbinger documentation built on July 10, 2026, 5:07 p.m.