Chart Axis with no Data

Guzzlr

Well-known Member
Joined
Apr 20, 2009
Messages
982
Office Version
  1. 2021
Platform
  1. Windows
Hello all
I have a simple bar chart, however there is large gaps in the Date axis because there is no data associated with the date.
How do I only graph the date/data so the dates with no data do not show?, so the large gaps do not show and take up space?

Thank you

1723828968172.png
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
Since you're using Excel 2021 the easiest is probably to use a formula to filter the data, and then plot that. So in the example data below, add the =FILTER formula at E4 and then use E4:F17 as your chart range.
When you first plot it, it will look like your problem is not fixed, but right-click on the X axis, choose Format axis and change the axis type to Text.
1723885701864.png


Book1
ABCDEF
1
2
3DateNumberFiltered data
41/01/2024141/01/202414
55/01/20246/02/202411
69/01/202410/02/202432
713/01/202414/02/202438
817/01/202413/03/202418
921/01/202417/03/202423
1025/01/202421/03/202446
1129/01/202425/03/20247
122/02/202429/03/20248
136/02/20241128/05/202431
1410/02/2024321/06/20248
1514/02/20243821/06/202447
1618/02/202429/06/202421
1722/02/20243/07/202415
1826/02/2024
191/03/2024
205/03/2024
219/03/2024
2213/03/202418
2317/03/202423
2421/03/202446
2525/03/20247
2629/03/20248
272/04/2024
286/04/2024
2910/04/2024
3014/04/2024
3118/04/2024
3222/04/2024
3326/04/2024
3430/04/2024
354/05/2024
368/05/2024
3712/05/2024
3816/05/2024
3920/05/2024
4024/05/2024
4128/05/202431
421/06/20248
435/06/2024
449/06/2024
4513/06/2024
4617/06/2024
4721/06/202447
4825/06/2024
4929/06/202421
503/07/202415
source_data
Cell Formulas
RangeFormula
E4:F17E4=FILTER(B4:C50,C4:C50<>"")
B5:B50B5=B4+4
Dynamic array formulas.
 
Upvote 0
Solution

Forum statistics

Threads
1,223,954
Messages
6,175,603
Members
452,660
Latest member
Zatman

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