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.

Pie Chart with a Measure and Column

Capture.JPGI have a measure which calculates distinct number of people with TCM reports, in this case, say 424. The total number of distinct clients is 976, which is calculated by the column people _id  using Count (Distinct). How do I show this in a pie chart? 

I want the total 976 as 100% and the ones with TCM reports as 424 i.e. 43.44%.

Status: New
Comments
v-robertq-msft
Community Support

Hi, @tammymukhia 

According to your description, I think you can achieve this using two measures as the percentage value in the pie chart, like this:

This is my test data:

vrobertqmsft_0-1624516523061.png

 

Total percent = DIVIDE(COUNTX(ALL('Table'),[Column1]),COUNTX(ALL('Table'),[Column1]))
A percent = DIVIDE(COUNTX(FILTER(ALL('Table'),[Column1]="A"),[Column1]),COUNTX(ALL('Table'),[Column1]))

vrobertqmsft_1-1624516523063.png

vrobertqmsft_2-1624516523070.png

vrobertqmsft_3-1624516523077.png

 

And you can get what you want.

Thank you very much!

 

Best Regards,

Community Support Team _Robert Qin

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

tammymukhia
Regular Visitor

Hi @v-robertq-msft ,

 

Thank you so much for responding. I was able to get the percent correct.

 

1.JPG

Is there a way to show both the % and the actual number (in my case :  total - 976 ; TCM reports - 424)?

 

Also, When I selected a different time range, the pie chart seems off. 72.09% should cover more area of pie chart and I think it is still using percent of total rather than data value.

 

2.JPG3.JPG

 

Thank you once again! I appreciate it!

v-robertq-msft
Community Support

Hi, 

Yes, I just used the measure to get the percent value you wanted, but it still covers the original area of the pie chart.

vrobertqmsft_0-1624585718549.png

 

As far as I’m concerned, pie chart in Power BI can not achieve the function to display percentage but cover the corresponding area of pie chart.

But I think it’s a good idea. You can go to the Power BI Idea to submit a new idea so that people with the same idea can vote for you. I will also vote for you.

vrobertqmsft_1-1624585718551.png

 

Thank you very much!

 

Best Regards,

Community Support Team _Robert Qin

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