Hello,
-
What Grafana version and what operating system are you using?
V9.3.6
-
What are you trying to achieve?
I want to plot bars as sub-meters and their total
-
How are you trying to achieve it?
I use the bar chart visualization.
-
What happened?
When I choose the stack option, all or none series are impacted.
-
What did you expect to happen?
I would lie to stack all sub-meters but not the total bar.
I thought overrides options could allow to modify some series but there is no stack option available
How to stack some bars but not some others ?
BR
Hi @swiftice3253,
Thanks for opening this post.
You can do this with the Override option and select a customized standard unit for time
I attached a screencast (open it in a new window as will be easier to zoom in and view more clearly)
![timestamp-overwrite 2022-09-26 11-46](https://us1.discourse-cdn.com/grafanastaging/original/3X/4/7/47462bda20965801efb08e9ad9a13bd1a074d230.gif)
Let us know if this helps.
Hello @usman.ahmad,
Thank you for your reply.
I haven’t explained clearly enough.
Let’s assume that I have 3 series : EnergyMeter1, EnergyMeter2 and TotalEnergy
I would like to draw a bargraph with EnergyMeter1 & EnergyMeter2 stacked just near TotalEnergy not stacked
Is it better explained ?
Hi @swiftice3253
Thanks for providing the details.
I have created a mock data by using random walk
A separate query for EnergyMeter1 and EnergyMeter2
Then using Transformation to get a sum of both above as Total Engery.
Then use Bar chart visualisation
Then go into settings on right side under Bar Chart → Stacking → Select either Normal OR 100%
Also use “Highlight full area on hover” for better visual appear when hovering mouse.
I attached a screencast (open it in a new window as will be easier to zoom in and view more clearly)
![bar-chart-not-stacked](https://us1.discourse-cdn.com/grafanastaging/original/3X/b/2/b26943fb3f241425c37aa43eeaaece60188ed4fc.gif)
Let us know if this helps.