Forum Discussion
Percentage
- 3 years ago
Hi , Pavani
According to your description, you want to show top5 death in the pie chart and the percentage you want to show the same for the total death .
First of all, the percentage of Pie Chart is automatically calculated according to the value. If you want to modify the data label forcibly, you can use the new function dynamic measure of Desktop.For this , you can refer to :
Create dynamic format strings for measures in Power BI Desktop - Power BI | Microsoft LearnAnd for your need , you can also refer to my steps:
This is my test data:We can create these measures and i think some of them you have created in your side :
Total Death = CALCULATE( SUM('Table'[Death] ) , ALL('Table'))Percentage = FORMAT( SUM('Table'[Death] ) /[Total Death] , "0.00%")Measure 2 = SUM('Table'[Death])Then we can put the Measure 2 as the value in the pie chart and we open the "Dynamic" for the [Measure 2 ]:
And then we put this in it:""""& FORMAT(SUM('Table'[Death]),"0") & "(" & [Percentage] & ")"The result as follows:Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Thank you!
If I required top5 countries what I need to give percentage .
Hi , Pavani
According to your description, you want to show top5 death in the pie chart and the percentage you want to show the same for the total death .
Create dynamic format strings for measures in Power BI Desktop - Power BI | Microsoft Learn
This is my test data:
We can create these measures and i think some of them you have created in your side :
And then we put this in it:
Thank you for your time and sharing, and thank you for your support and understanding of PowerBI!
Best Regards,
Aniya Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly