ES|QL TO_EXPONENTIAL_HISTOGRAM function
field-
The histogram value to be converted
Converts histogram-like values to an exponential histogram.
| field | result |
|---|---|
| exponential_histogram | exponential_histogram |
| histogram | exponential_histogram |
| tdigest | exponential_histogram |
FROM histogram_standard_index
| WHERE STARTS_WITH(instance, "hand-rolled")
| EVAL converted = to_exponential_histogram(responseTime)
| SORT instance
| KEEP responseTime, converted
;
| responseTime:histogram | converted:exponential_histogram |
|---|---|
| {"values":[0.1,0.2,0.3,0.4,0.5], "counts":[3,7,23,12,6]} | {"scale":38,"sum":16.4,"min":0.1,"max":0.5,"positive":{"indices":[-913124641742,-638246734798,-477453466959,-363368827854,-274877906945],"counts":[3,7,23,12,6]}} |
| {"values":[], "counts":[]} | {"scale":38} |
| ; |