View Source ddskerl behaviour (ddskerl v0.2.1)

DDSketch behaviour.

Summary

Types

DDSketch instance.

Options for the DDSketch.

Callbacks

Insert a value into the DDSketch.

Merge two DDSketch instances.

Create a new DDSketch instance.

Calculate the quantile of a DDSketch.

Get the sum number of elements in the DDSketch.

Get the total number of elements in the DDSketch.

Types

ddsketch()

-type ddsketch() :: dynamic().

DDSketch instance.

opts()

-type opts() :: #{atom() := dynamic()}.

Options for the DDSketch.

Callbacks

insert/2

-callback insert(ddsketch(), number()) -> ddsketch().

Insert a value into the DDSketch.

merge/2

-callback merge(ddsketch(), ddsketch()) -> ddsketch().

Merge two DDSketch instances.

new/1

-callback new(opts()) -> ddsketch().

Create a new DDSketch instance.

quantile/2

-callback quantile(ddsketch(), float()) -> float() | undefined.

Calculate the quantile of a DDSketch.

sum/1

-callback sum(ddsketch()) -> number().

Get the sum number of elements in the DDSketch.

total/1

-callback total(ddsketch()) -> non_neg_integer().

Get the total number of elements in the DDSketch.