How to Convert Value to Percentage in Bar Graph in Tableau

How do you convert a value to a percentage in a bar graph in this example I have Revenue by business line the graph on the left is showing the amount and the graph on the right is showing the percent of total let’s show you how to do this in tableau If this is your first time here make sure you like And subscribe for more Tableau content I’m going to show you two ways how to show percentage of total let’s start by using a table calculation I’m just going to take Revenue. Put it onto the view right next to my first Revenue. I’m going to click the drop down on the field go to Quick table calculation and choose percentage of total that’s going to give me the percentage of total for each business line to write that one more way with a calculated field we’ll call this percent. LOD for level detail. This time I want to take sum of Revenue divided by the total in the table that would give you percent of total so let’s divide by start by typing exclude drag in business line put a colon drag in sum of Revenue add a curly bracket level of detail calculations are not aggregated so I need to graph this calculation with a sum. So now the denominator effectively says exclude business line and give me the sum of Revenue so across the entire table give me the sum take the revenue and divide it by that total click ok Drag that to The View and you’ll see that I get 15 for the first bar which is same as the percentage of total.

7 views0 comments