Forum Discussion
Percentage Differences Boggle
- Anonymous7 years ago
I had already been down that road. The solution was to add the order to the tool tips (minimum), then select it from the "More Options" on the visual itself.
Anonymous add following measure to get %
% = DIVIDE( COUNT(Table[Distance Category]), CALCULATE( COUNT( Table[Distance Category] ), ALLSELECTED( Table[Distance Category] ) )
you can also have a measure for count and replace COUNT in above expression with your measure
I tried that, but it returns 1 for all categories:
- parry2k7 years agoSuper User
Anonymoushmm, seems like I'm missing something here, looks like you have multiple table with relationship, can you share what does that relationship looks like
also can you make sure on x-axis you are using the same distance category column which you used in DAX ALLSELECTED Function.
- Anonymous7 years agoNot applicable
For a moment, it worked, but now I'm befuddled.All I am using this other table for is to get the X axis member to appear in order.
The Pct formula:
Pct = DIVIDE([Distance Count], CALCULATE([Distance Count], ALLSELECTED('Distance Category'[Category])))Percentages are correct, but the order is off.If I replace "Category" with "Distance Category", then I get all values equal to 1.0- v-lili6-msft7 years agoCommunity Support
HI, Anonymous
You could use Sort by column in Power BI Desktop for order.
for the result is 1.0, it involves row context in calculation, you could learn about it.
If you still have problem, please share your sample pbix file.
Best Regards,
Lin