Skip to content

[chart] Allow to change sorting of Grouped/Stacked bars #13269

Description

Is your feature request related to a problem? Please describe.
In Time-series bar chart, when user creates groups of bars(grouped/stacked), the order of bars in a group/stack is based on the value of metric(descending).
In case of Bar chart, the order is based on 'breakdown' dimension value(ascending).
There is an option of selecting 'Sort by', but that is just to calculate which bars will be part of chart when series limit is applied.

Describe the solution you'd like
Here, user should be able to sort the bars based on the value of 'Group by' dimension(for time-series bar chart) or by metric value(for bar chart).
For example in below chart(sample flights data), user can sort the bars in each group/stack alphabetically(by airline company) to show 'AA' in left most or right most.
image
image

In case of bar chart, the sorting of bars is alphabetical(ascending) value of 'breakdown' dimension, it should be possiblle to change this behavior as well.
image

Describe alternatives you've considered
A more complex feature can be to sort the bars based on some other metric(as already available for series limit).

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions