Histogram
Use a histogram to show how raw values are distributed across generated numeric bins.
Every preview on this page is generated from the YAML shown below it using a fixed documentation dataset.
Basic distribution
Set query.table and one numeric measure so LeapView can bin raw delivery values and count observations in each interval.
Key fields
visuals:
delivery_histogram:
title: Delivery days histogram
description: Buckets order volume by delivery duration.
type: histogram
presentation:
histogram_bins: 16
query:
table: orders
measures:
delivery_days: null
Custom bins
Change the raw measure to revenue and use presentation.bin_count to balance distribution detail against the available chart width.
Key fields
visuals:
revenue_histogram:
title: Revenue histogram
type: histogram
presentation:
histogram_bins: 18
query:
table: orders
measures:
revenue: null
Labeled bins
Use fewer bins for the bounded review scale and enable show_labels when every bin count should be visible without hovering.
Key fields
visuals:
review_histogram:
title: Review score histogram
type: histogram
presentation:
histogram_bins: 10
show_labels: true
query:
table: orders
measures:
review_score: null
API reference
Kind: chart. Renderer: echarts. Supported result shapes: binned_measure.
| Field | Type | Default | Allowed values | Description |
|---|---|---|---|---|
query.measures | measure mapping | — | — | Selects the governed semantic measures consumed by the visual shape. |
query.table | string | — | — | Selects the fact table when the semantic model cannot infer one from the referenced fields. |
presentation.histogram_bins | integer | 20 | 5–60 | Controls the number of equal-width histogram bins. |
presentation.show_labels | boolean | false | true false | Shows value labels directly on chart marks. |
Accessibility. Use a descriptive title and unit, and do not rely on color alone to distinguish series or values.