tdigest_combine

tdigest_combine(digest: tdigest) -> digest

Merges multiple tdigest states inside each aggregate group, returning a digest of the same generic type as the input column. It is aggregate- and window-capable, and is suited to hierarchical rollups after partial tdigest_agg results. The merge is approximate like any t-digest operation; null inputs follow normal aggregate null rules of the surrounding verb.

Domain

This is an aggregate function (aggregates rows over a group in aggregate verbs).

This is a window function (calculates over a group of multiple input rows using windowing).

Categories

Examples

align 10m, frame(back: 10m), o: tdigest_combine(partial_digest)

Merges pre-aggregated digest states emitted from an upstream pipeline stage into one digest per ten-minute bucket.