In a Tableau line chart, Tableau automatically places null values to 0 (zero) on the X axis.
This is technically incorrect; NULL means the value is unknown, not that it’s zero.
For example, you’re trending this year and the previous years data for sales (or whatever measure) with the months on the X axis and the sales on the Y. If it’s mid-year, future months won’t have any sales data as they haven’t yet happened.
Usually, it is preferable to remove those Null values to tidy the line chart.
The data source contains data up to May of the latest year.
This date is important because in the line charts you see Tableau has included the future values – June to December.
These dates haven’t yet happened, so they don’t exist in the data source. Therefore they are Null, so Tableau assigns a 0 value.
How to remove the Null values from a line chart
To remove or hide the Null values, format the green pill on the Rows shelf.
Right-click on the pill, select format, opening the Format window.
To remove the Null values from your line chart, select the Pane section of the format window. In this section, at the bottom, notice it has the option ‘Special Values (eg. NULL).
By default Null marks are set to Show. Change this to Hide in the Marks drop down and the Null values will no longer be on your chart.
For another technique at hiding nulls check this article.