cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Ying_P Regular Visitor
Regular Visitor

Hide some tags in a chart

Hi all,

 

I have a question about how to hide some tags in a chart.

 

For example, in the chart below, I'd like to show only the top 6 tags. For the others, I'd like to hide them instead of excluding them. I have tried the RANKX function, but it excluded all the other tags and the percentages changed. Please let me know if you have a solution.

 

Capture.JPG

 

Great thanks!

2 ACCEPTED SOLUTIONS

Accepted Solutions
Highlighted
mravestein Frequent Visitor
Frequent Visitor

Re: Hide some tags in a chart

Hi Ying,

 

To do this you can use the default Top N filter in PowerBI. 

 

Make sure you have the visual selected, and go to the filter pane. Under "Visual Filter" select the value that tells the description.

Now select here in the filter options "Top N"

2017-03-30 16_36_38-YearMonth - Power BI Desktop.png

 

Fill in the number of Top value's you want to show.

Drag in the column that creates the % value in your visual and click on "Apply".

2017-03-30 16_37_00-YearMonth - Power BI Desktop.png

 

This should do the trick for the visual

Moderator v-caliao-msft
Moderator

Re: Hide some tags in a chart

Hi @Ying_P,

 

How do you calculate the percentage? I have tested it on my locla environemnt, we cannot reproduce this issue.
Capture.PNGCapture1.PNG

 

In your scenario, please provide us some sample data and the formular that use to calculate this percentage, so that we can make further analysis.

 

Regards,

Charlie Liao

6 REPLIES 6
Highlighted
mravestein Frequent Visitor
Frequent Visitor

Re: Hide some tags in a chart

Hi Ying,

 

To do this you can use the default Top N filter in PowerBI. 

 

Make sure you have the visual selected, and go to the filter pane. Under "Visual Filter" select the value that tells the description.

Now select here in the filter options "Top N"

2017-03-30 16_36_38-YearMonth - Power BI Desktop.png

 

Fill in the number of Top value's you want to show.

Drag in the column that creates the % value in your visual and click on "Apply".

2017-03-30 16_37_00-YearMonth - Power BI Desktop.png

 

This should do the trick for the visual

Ying_P Regular Visitor
Regular Visitor

Re: Hide some tags in a chart

Thank you @mravestein for your detailed instruction!

 

However, Top N filter filters out the other tags and leads to a change in distribution. I want to include all tags for calculation but just don't let them show up in the chart.

 

Do you know how to do this?

 

Thanks!

mravestein Frequent Visitor
Frequent Visitor

Re: Hide some tags in a chart

If I understand it correctly, you want to see the following value's in the chart:

Finding info - 9.62

Detailed info 6.11

Navigation 5.30

Strores/deal 5.01

Search 3.51

Price info 3.46

 

If you apply the filter I've mentioned on the chart as visual filter, i'm expecting that result

Ying_P Regular Visitor
Regular Visitor

Re: Hide some tags in a chart

Hi @mravestein,

 

I appreciate your help!

 

After I applied the filter, I got a different result. Could you identify what's wrong with my operation?

 

2.JPG1.JPG

 

Thanks a lot!

Moderator v-caliao-msft
Moderator

Re: Hide some tags in a chart

Hi @Ying_P,

 

How do you calculate the percentage? I have tested it on my locla environemnt, we cannot reproduce this issue.
Capture.PNGCapture1.PNG

 

In your scenario, please provide us some sample data and the formular that use to calculate this percentage, so that we can make further analysis.

 

Regards,

Charlie Liao

Ying_P Regular Visitor
Regular Visitor

Re: Hide some tags in a chart

Hi @v-caliao-msft,

 

You were right! I found that something was wrong in my calculation of percentage. I used (count of each category)/ (count of total), so, when the top N filter was added, the base of total became smaller, and that affected the percentage.

 

Do you know if there is a way to keep the (count of total) as a fixed number, so it won't be affected by applying the Top N filter.

 

Thanks a lot!