FIGURE: plot monthly data and only present the years
1 回表示 (過去 30 日間)
古いコメントを表示
Hi I'm trying to plot monthly data and only present the years on the x-axis. Is this method correct?
startdate = datenum('31-01-2002','dd-mm-yyyy')
enddate = datenum('31-12-2010','dd-mm-yyyy')
dt = linspace(startdate,enddate,108);
data = rand(numel(dt),1);
plot(dt,data)
datetick('x','yyyy','keepticks')
2 件のコメント
採用された回答
Azzi Abdelmalek
2012 年 11 月 27 日
編集済み: Azzi Abdelmalek
2012 年 11 月 27 日
try this
dt=datenum(2002,(1:120),1)
0 件のコメント
その他の回答 (0 件)
参考
カテゴリ
Help Center および File Exchange で Descriptive Statistics and Visualization についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!