From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Plot date labels
Date: Thu, 9 Aug 2012 18:06:17 +0000 (UTC)
Organization: GMO LLC
Lines: 7
Message-ID: <k00u6p$3hq$>
References: <k00t34$t35$>
Reply-To: <HIDDEN>
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
X-Trace: 1344535577 3642 (9 Aug 2012 18:06:17 GMT)
NNTP-Posting-Date: Thu, 9 Aug 2012 18:06:17 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 2383542
Xref: comp.soft-sys.matlab:776079

"mklcst mklcst" wrote in message <k00t34$t35$>...
> Hi everybody, I have a 2 column matrix to plot, one with the dates in number and the other column with the values. My problem is the date labels to plot on the x axis, because if I have 100obs I cannot print 100 date labels. In order to face it I tried with some loops but I have an inconsistency on the time range (same space interval different time period of months). I suppose there is an easy way to do it, so if I have a column-vector x with the dates in number and y with the values. What I have to do in order to plot it?

Providing your number-dates are Matlab datenums, just plot(x,y) as normal and then do:
datetick x   % or datetick('x') 

Alternatively, open the documentation with "doc" and search for something like "plot dates".