Handling Missing Data in Line Chart

smcferrin

New Member
Joined
Nov 2, 2011
Messages
2
I have a line chart that shows monthly trends over a two year period. Chart data is sourced from a table that I built using a pivot table and the GetPivotData function. I am also using a drop-down control that allows a user to select among different countries (e.g., US, Canada, Mexico, etc.) My data starts in the middle of the first year and I have not yet reached the end of the second year. As a result I am missing data in the first months of year 1 and the last months of year 2. The starting point will vary by Country.I want to eliminate the lines connecting those missing data points. I have set the data source to treat missing data as gaps. However, the GetPivotData function returns a value of zero for missing data. I have tried replacing zeroes with zero-length strings but it appears that the chart interprets those as a valid data rather than missing data. Any other ideas on how I can eliminate the unsightly chart lines?
 

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type
Welcome to MrExcel.
Try replacing zeros with #N/A. (can be entered as such or as a function =NA())
 
Upvote 0
This thread is very old but my question is exactly as stated, but different from above person. I have created line graphs using data in a table. For most part the graphs are fine, but one graph skips one of the values in the table. When I select the line, the value is included in the colored box, and the values before and after it are graphed. All the values are generated by formulas. Have I accidentally hidden the cell or something? I have no idea how to fix it.
 
Upvote 0

Forum statistics

Threads
1,223,192
Messages
6,170,647
Members
452,344
Latest member
LarryRSch

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