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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
hani17417164
Frequent Visitor

Using donut chart/ pie chart as filter for a measure

Hi!

 

I'm encountering issue on using donut/pie chart as a filter for a measure.

So, I have data on (let's say) thousands of people who likes milk chocolate and/dark chocolate, and their score towards milk/dark chocolate (from a scale 0-10). A person can either likes/dislikes milk/dark chocolate.

 

The data looks something like this:

table.PNG

 

Goal: I want to know how NPS milk chocolate differs for milk chocolate.

 

So, this is what I did:

  • I created an NPS measure from the 0-10 score data displayed as "NPS milk chocolate"
  • I convert "yes" to "1" and "no" to (blank)
  • I created donut/pie chart to diplay how many person likes/dislikes milk/dark chocolate as follows:

page1.PNG

  • When I use filter and choose "1" which means yes to the question "likes milk chocolate?", the Score milk chocolate becomes 24.81.

likes milkchoc.PNG

  • But, when I click on the donut chart to select "Likes milk chocolate", the Score doesn't reflect the "Likes milk chocolate" I selected in the donut chart. --> I would expect to have 24.81 in the Score instead of 4.96. --> So, shouldn't this work in PowerBI? What could I do to make this work?

I tried to look for a solution in the forum, but the only thing I could find is to transform the table to have likes/dislikes milk/dark chocolate into one column (@https://community.powerbi.com/t5/Desktop/Donut-Chart-Using-Multiple-Columns/td-p/735950).

I need an easier solution if possible since transforming data may not work for me on a much complex data (e.g: what if I have 100 variant of chocolate, and one people can answer the question multiple times).

2 REPLIES 2
v-xicai
Community Support
Community Support

Hi @hani17417164 ,

 

Based on my test, I can filter the measure by selecting a legend item in Donut chart or Pie chart. Have you made "Edit Interactions" settings for the Donut chart or Pie chart like what is shown in this article, which denies the Donut chart or Pie Chart the interactions with other visuals? 

 

Could you please show us the formula of "NPS milk chocolate" for further analysis?

 

Best Regards,

Amy

 

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

 

Hi @v-xicai ,

 

Yes, I did make sure that the visualisation has active interaction, and it still doesnt work

 

Here is more details you asked:

table2.PNG

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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