hide empty segment in a donut chart

Dave 💎
edited March 7, 2017 in Questions

Anyone would know of a way to hide segments (category) in a donut chart when there are equal to 0 ?

In the example below, i would like to be able to only see the 2 categories >0 (red and orange one) the other 4 should not even show at all




  • J.
    J. 💎
    edited March 7, 2017

    The short answer is that Charts show whatever is in your model data, so if it's in the model, even with a zero value, it'll still show. The only way to get rid of them without writing some code at this point is to not have them included in your model. If that's not an option, you can use a Before Render Snippet (see this and this for some good community resources) to remove the series that you don't want shown. 
  • Bill McCullough
    Bill McCullough 💎💎
    edited May 3, 2016
    Dave would a 'having' condition work for you?  You could filter for results greater than zero.  Here is  a link on how to do this.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!