Skip to content

docs: missing documentation for MEDIAN_TDIGEST_WEIGHTED aggregate function #3297

@sundy-li

Description

@sundy-li

What's Missing

The MEDIAN_TDIGEST_WEIGHTED aggregate function is registered in the source but has no documentation page.

Source File

/workspace/databend/src/query/functions/src/aggregates/aggregate_quantile_tdigest_weighted.rs

Registration in /workspace/databend/src/query/functions/src/aggregates/aggregator.rs:

factory.register(
    "median_tdigest_weighted",
    aggregate_median_tdigest_weighted_function_desc(),
);

What It Does

MEDIAN_TDIGEST_WEIGHTED computes the approximate median of a weighted numeric data sequence using the t-digest algorithm. It takes two arguments: the value expression and a weight expression (integer), allowing rows to contribute proportionally to the result.

Syntax

MEDIAN_TDIGEST_WEIGHTED(<expr>, <weight>)

Suggested Doc Location

/workspace/databend-docs/docs/en/sql-reference/20-sql-functions/07-aggregate-functions/aggregate-median-tdigest-weighted.md

A new page should be created documenting the syntax, arguments (value and weight), return type (Float64), and an example showing weighted median computation.

Note: This is distinct from MEDIAN_TDIGEST (single-argument, already documented at aggregate-median-tdigest.md) and from QUANTILE_TDIGEST_WEIGHTED (already documented at aggregate-quantile-tdigest-weighted.md).

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions