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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
Irek
Helper II
Helper II

Stacked Bar Chart Percentage Share per category, with bars size by value.

Hello, 

 

It is possible to have a bar chart showing percentage by category (like second picture) but with bar size dependet from category total value like in first picture ? 

 

I know that I can add my % calculation to Tooltips but I need % to be visible all the time not only after mouse over . 

 

 

 

Irek_0-1712297796247.png

 

 

Thank you 

Marcin 

1 ACCEPTED SOLUTION
Gabry
Super User
Super User

You can easily accomplish this. First, place the total value measure on the axis of the chart. Then, navigate to the format pane and under 'Data Label,' select 'Value.' From there, you can insert your percentage measure. This way, the columns will be sized based on value, while the data label will display the percentage

Gabry_0-1712302531725.png

 

View solution in original post

4 REPLIES 4
Gabry
Super User
Super User

You can easily accomplish this. First, place the total value measure on the axis of the chart. Then, navigate to the format pane and under 'Data Label,' select 'Value.' From there, you can insert your percentage measure. This way, the columns will be sized based on value, while the data label will display the percentage

Gabry_0-1712302531725.png

 

Thank you!!!! Easy !!!

Have a great day. 

Marcin 

Joe_Barry
Super User
Super User

Hi @Irek 

 

It's possible if you create a measure for this and convert it to %. Should the Result show the % of  all employees?

 

You need a meausre to calculate all Employees that ignores the filter context

Employees All = CALCULATE(COUNT(Employees[EmployeeID]), ALL(Employees)

 

Then you need to create a % measure

 

% Employees = DIVIDE(COUNT(Employees[EmployeeID]), [Employees All], 0)

 Convert to % and add to a clustered bar chart

 

Joe

 

If you found my answer helpful and it solved your issue, please accept as solution




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!





Learn about the Star Schema, it will solve many issues in Power BI!

Date tables help! Learn more



LinkedIn
Let's connect on LinkedIn


Hi Joe, 

Thank you for your respond. % result should be per category like in second picture I attached. in category 0-1 year I have 1 Leap and 6 blanks, total 7 , bar chart size should be represent that (be smaller than bar chart with 10 ) but % calculation should be 1/7 and 6/7 . 

I can do value with % in Tooltips but goal is to have bar chart size for value (7) and data labels for % share in category (lenght of service) 

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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