Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Nomadexchris
Frequent Visitor

Show data label as percentage of total for stacked bar chart instead of absolute value

Hi guys,

 

I was wondering if there is a workaround for Power BI stacked bar chart to show percentage of total (example below) instead of absolute value. By default only 100% stacked column chart could show data label in percentages but I would like to replicate sometime similar to the chart below instead. Thanks!

 

 

Nomadexchris_0-1625822709069.png

 

6 REPLIES 6
voldelord
New Member

excellent

tbennett93
Frequent Visitor

A half-solution I have found to allow you to simultaneously display absolute values and percentages is to use a Line + Stacked Column chart and put your percentage measure on the secondary y-axis and change your line width to 0px. It does achieve a different result to what you're after as the percentage won't position themselves inside the stacked bars like you're requesting. They would either position according to the 0->100% secondary y-axis or you could get a single measure to display at the bottom of each column, like this:

tbennett93_0-1674568395073.png

 

This shows the absolute values as well as the percentage of purple vs pink

Anonymous
Not applicable

Hello @Nomadexchris, any updates on the issue? I have the same use case, did you find any workaround?

Kind regards.

amitchandak
Super User
Super User

@Nomadexchris , You have to create a % measure and then show that as value and a total measure that you have to show as line and make line color same as background or #FFFFFF00

 

Meausre1 = calculate([measure], removefilters(Table[series]))

or

Meausre1 = calculate([measure], filters(allselected(Table[series]), Table[series] = max(Table[series])))

 

% total = divide([Measure], [Measure1])

 

Use Measure 1 and % total

 

 

 

Dear @amitchandak, thanks for your response. However, I think the result will be a 100% stacked chart with a total amount. However, this would not allow me to show the overall trend using the bar chart

Hi @Nomadexchris have you had any luck in recreating the chart from your example?

 

I have the same use case and can't figure a way around it and all the solutions from Microsoft experts all point to 100% stacked charts. 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.