From: foehner on 9 Jun 2010 01:52 Hi, I have a plot where the x-axis does not reflect the chosen time period: The start_date is e.g. datenum 2009,8,14 and the end_date is 2009,8,19 B = find(sdate_b >= start_date & sdate_b <= end_date); gives me the index for value b which is multiplied thereafter with another station (i plot the hydrostatic differences in a valley per day and station). sdatelim = [start_date end_date]; sdaterange = sdatelim(1):sdatelim(2); for i = 1:length(sdaterange) j = find(sdate_b >= sdaterange(i) & sdate_b < sdaterange(i)+1); diffb(i) = abs(max(dz_b(j))-min(dz_b(j))); Here I calculate the daily absolute values of dz (= diffb) of b The I plot this and six other values and the figure looks as follows: http://img156.imageshack.us/img156/4924/differences.png set(gca,'xlim',sdatelim); The start day (14. august) is on the y axis and the end_date (19. august) is set to zero. My question is: what/where do I have to change to obtain also the start and end_date within the graph? Thanks very much (i'm a matlab greenhorn), Felix
From: dpb on 9 Jun 2010 15:58 foehner wrote: .... > My question is: what/where do I have to change to obtain also > the start and end_date within the graph? .... doc datetick I think will get you where you want to go... --
|
Pages: 1 Prev: Problem with Installation on Mac OS X 10.6.2 Next: Compiling executable with Mingw |