Gauge ordering by value calculated in bucket script aggregation

Hello,

I'm using elastic agent with its system integration to collect metrics and I want to display the disk use per host as gauges. It's achieved by calculating the percentual use in a bucket script:

The ordering doesn't make much sense because I actually want to sort by the computed value (the percentual use) which makes it comparable between hosts. Like this it just looks random to the enduser.
Interesting fact - the "Top N" display style for some reason sorts as I would want it but there I don't like that if the top 1 value is 47.7%, the bar fills the entire line which visually suggest something is full, although it's not even filled by half.

I hope I gave the necessary information for you to understand my issue. Kind regards.

Edit: I add a screenshot of the current ordering to give an impression

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.