How to Viz: Add Labels inside the end of a Bar chart
Note: This is just to explore and try to do something different and out of the box. It is a request from my side to always look at best practices for data visualizations before deploying this into production.
Load Sample Superstore data. Create a Bar Chart by adding Region and Sales to Rows and Columns respectively.
I can add labels by dragging Sales to Label or going to Show Mark Labels from the Mark Card.
I want to add labels inside and at the end. How to do it?
After creating a Bar chart, Add a Reference Line and add it at the Cell Level.
If it goes well, it will look as shown below.
A dialog box appears. Choose SUM(Sales) in the Value section and keep it as Average. Choose Label as Value and Tooltip as None.
Now, we need to format Reference Line. Right-click on any Reference Line and then click Format.
In Reference Line Label, Choose Alignment as Custom. In Horizontal, choose Left and Vertical as Middle. If it goes well, we should see the following.
We need to do a little formatting. Now, we need to format Reference Line. Right-click on any Reference Line and then click Format. In the Reference Line section, choose Line as None. Then choose Font color and White and Shading as 0%. If it goes well, you will see the following.
Thanks for reading
Vignesh Suresh