Struct elastiql::aggregation::types::VariableWidthHistogram[][src]

pub struct VariableWidthHistogram {
    pub field: String,
    pub buckets: u64,
}
Expand description

Variable width histogram is a multi-bucket aggregation similar to histogram. However, the width of each bucket is not specified. Rather, a target number of buckets is provided and bucket intervals are dynamically determined based on the document distribution. This is done using a simple one-pass document clustering algorithm that aims to obtain low distances between bucket centroids. Unlike other multi-bucket aggregations, the intervals will not necessarily have a uniform width.

Note: until GraphQL Union input types are supported, either calendarInterval or fixedInterval must be specified but not both.

Fields

field: String

The field to perform the aggregation over.

buckets: u64

The target number of buckets.

Implementations

Create a builder for building VariableWidthHistogram. On the builder, call .field(...), .buckets(...) to set the values of the fields. Finally, call .build() to create the instance of VariableWidthHistogram.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.