How to Remove Zero Data Labels in Excel Graph (3 Easy Ways)

We have the following dataset containing records of marks for 3 subjects of some students. Among the students, two of them got 0 in two different subjects. After plotting them as Line Chart, Column Chart, and Pie Chart we can see that the Line Chart is showing zero data labels. The other two forms are avoiding the zero data labels. We will discuss more ways to remove the zero data labels from the Line Chart.

how to remove zero data labels in excel graph

We have used Microsoft Excel 365 version for this article, you can use any other version according to your convenience.


Method 1 – Using the NA Function to Remove Zero Data Labels

We are going to replace zero in Physics for Emily and in Maths for Sheldon with #N/A to avoid zero data labels.

NA function


Case 1 – Use the NA Function with the Find and Replace Option

Steps:

  • Select the range and go to the Home tab and the Editing group.
  • Select the Find & Select dropdown and choose Replace option.

how to remove zero data labels in excel graph

The Find and Replace dialog box will open up.

  • Type the following in the first two boxes.
    Find what → 0
    Replace with → =NA()
  • Select the Replace All option.

NA function

A message box will appear which informs about replacements.

  • Click on OK.

NA function

The zero values will be replaced by #N/A and the graphs are not showing zero data labels here anymore.

how to remove zero data labels in excel graph


Case 2 – Use the NA Function for Formula

In the Minimum column, we have used the MIN function to get the minimum value between the marks of Maths and Chemistry and the graph is showing the minimum values with zero data label.

how to remove zero data labels in excel graph

Steps:

  • Enter the following formula in cell E4.
=IF(MIN(C4:D4)=0,NA(),MIN(C4:D4))

If the minimum value is zero, the IF function will return #N/A instead.

  • Drag down the Fill Handle tool.

NA function

The Zero value for Sheldon has been superseded with #N/A. The graph has also removed zero data labels.

NA function

READ MORE: How to Add Data Labels in Excel


Method 2 – Using the Filter Option

This method can only be used if your graph is plotted with single column values.

how to remove zero data labels in excel graph

Steps:

  • Select the dataset and go to the Home tab,
  • Select Sort & Filter and choose Filter (in the Editing group).

Filter option

The filter dropdown option will appear on the column headers.

  • Click on the dropdown symbol in the Maths column.

Filter option

  • Uncheck the box with the number 0 and press OK.

how to remove zero data labels in excel graph

We have removed the marks 0 in the row for Sheldon and our graph has also eliminated this 0 data label.

Filter option

Read More: How to Hide Zero Data Labels in Excel Chart


Method 3 – Using the Custom Number Format

Column charts may ignore zero data labels, but when we activate the data label option of the chart, we can see the zero data labels for the Physics and Maths series also in the chart.

how to remove zero data labels in excel graph

Steps:

  • Select the data labels of the Physics series and right-click on it.
  • Choose the Format Data Labels option.

custom number format

The Format Data Labels panel will appear.

  • Go to the Label Options and scroll down.

how to remove zero data labels in excel graph

  • Under the Number option, select the Category as Custom, then, in the Format Code box insert #””, and click on the Add button.

custom number format

We have removed the zero data label from the Physics series.

custom number format

  • Similarly, we can remove the zero data label from the selected Maths series as well.

how to remove zero data labels in excel graph

We have removed all of the zero data labels from the following chart.

custom number format

Read More: How to Format Data Labels in Excel


Practice Section

We have provided a practice section like below in each sheet on the right side.

practice


Download the Practice Workbook


Related Articles


<< Go Back To Data Labels in ExcelExcel Chart Elements | Excel Charts | Learn Excel

Get FREE Advanced Excel Exercises with Solutions!
Tanjima Hossain
Tanjima Hossain

TANJIMA HOSSAIN is a marine engineer who enjoys working with Excel and VBA programming. For her, programming is a handy, time-saving tool for managing data, files, and online tasks. She's skilled in Rhino3D, Maxsurf C++, MS Office, AutoCAD, and Excel & VBA, going beyond the basics. She holds a B.Sc. in Naval Architecture & Marine Engineering from BUET and is now a content developer. In this role, she creates tech-focused content centred around Excel and VBA. Apart from... Read Full Bio

We will be happy to hear your thoughts

Leave a reply

Advanced Excel Exercises with Solutions PDF

 

 

ExcelDemy
Logo