How to stop 0 values appearing on a column graph

kalim

Board Regular
Joined
Nov 17, 2010
Messages
87
Hi I am using a countif formula to count a certain creteria and then plot the results on a column graph.

The problem I have is that, if the count is 0 the column graph displays a 0 value.

How can I make excel not display a 0 value if that cell's value is 0?
I have tried an if statement with na() i.e

=IF(COUNTIF(A1:A20,answer=0),NA(),COUNTIF(A1:A20,answer))
but is does not work for this type of graph. It just displays an #N/A

Any suggestions?
Thanks.
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Would using double quotes instead of NA() work?
i.e.
Code:
=IF(COUNTIF(A1:A20,answer=0),"",COUNTIF(A1:A20,answer))
 
Upvote 0
Thanks for the reply.<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>
I have already tried that and the graph displays a 0, as the cell is not truly blank.<o:p></o:p>
<o:p></o:p>
Any other suggestions?<o:p></o:p>
 
Upvote 0
Why do you not want zero to appear on the chart, and what would you rather see?

This is what I currently get:

chart.PNG
 
Upvote 0
Thanks for the reply.

Add data labels (which I need) to those columns and you will get zero.

I am comparing two data values and it looks bad on the graph if there are alot of zeros there. As mentioned the graph is linked to a countif formula they will change as the workbook is altered.

What I need, is when the countif fomulas return a 0, the graph displays no value (blank) and not a value of 0.

Thanks.
 
Upvote 0
You can format the data values on the chart so that the 0 values do not appear. i.e. use a custom number format

0;;;

And it should look like this:

chart2.PNG
 
Upvote 0

Forum statistics

Threads
1,224,600
Messages
6,179,836
Members
452,947
Latest member
Gerry_F

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top