MATLAB Answers


How to skip time on X axis

Asked by ANKUR KUMAR on 22 Dec 2017

I am trying to plot a variable for January and July months.

T1 = datetime(2017,01,1):datetime(2017,01,31);
T2 =datetime(2017,07,1):datetime(2017,07,31);
T=[T1 T2];

T has the dates of January and July only. But when I plot T vs A (any data), then the Feb-June also comes up on X axis. How to skip in between dates on X axis. I have attached the plot.


Sign in to comment.


0 Answers

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today