cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
qsmith83
Post Partisan
Post Partisan

DAX for Percent of Column Total in Stacked Column Chart

Hi,

I just realized that the matrix table can show value as a percent of column total which is awesome. However when I made a copy of the same table and changed it to a stacked column chart, it didn't replicate same %values from the table. Also realized that the only option available in chart is "show value as a percent of grand total".

How do I make the stacked column chart replicate the table view with a dax measure? And also the values need to change dynamically based on slicer selections.

@VahidDM, @Greg_Deckler appreicate any help please. Thanks.

Screenshot 2021-10-08 170144.jpg

 

2 ACCEPTED SOLUTIONS

@VahidDMthank you that worked but not as intended i.e. values add up to 100% for all months. I need them to add up to 100% for the each month.

Also when applying filter on slicers, the numbers don't add up to 100%. How to incorporate slicer selection to ensure that the values add up to 100%?

Screenshot 2021-10-11 131225.jpg

 

View solution in original post

VahidDM
Community Champion
Community Champion

Hi @qsmith83 

 

Change the visual to 100% Stacked column chart.

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.

Appreciate your Kudos!!

 

View solution in original post

4 REPLIES 4
VahidDM
Community Champion
Community Champion

Hi @qsmith83 

 

Try this measure:

Measure = 
SUM ( 'Table'[TotalJobs] )
    / CALCULATE (
        SUM ( 'Table'[TotalJobs] ),
        ALLEXCEPT ( 'Table', 'Table'[LatestStatus] )
    )

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.

Appreciate your Kudos!!

 

@VahidDMthank you that worked but not as intended i.e. values add up to 100% for all months. I need them to add up to 100% for the each month.

Also when applying filter on slicers, the numbers don't add up to 100%. How to incorporate slicer selection to ensure that the values add up to 100%?

Screenshot 2021-10-11 131225.jpg

 

View solution in original post

Ah ok, perfect. Working now. Many thanks for your help @VahidDM , appreciate it

VahidDM
Community Champion
Community Champion

Hi @qsmith83 

 

Change the visual to 100% Stacked column chart.

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.

Appreciate your Kudos!!

 

View solution in original post

Helpful resources

Announcements
2022 Release Wave 1 760x460.png

2022 Release Wave 1 Plan

Power Platform release plan for the 2022 release wave 1 describes all new features releasing from April 2022 through September 2022.

Power BI December 2021 Update_carousel 768x460.jpg

Check it Out!

Click here to read more about the December 2021 Updates!

Jan 2022 Dev Camp 768x460 copy.png

Power BI Dev Camp- January 27th, 2022

Mark your calendars and join us for our next Power BI Dev Camp!

Top Solution Authors
Top Kudoed Authors