Year conversion on figure wrong
2 ビュー (過去 30 日間)
古いコメントを表示
If I read in a date, say 7/15/2017, but I read it in as 42931.00, when in MATLAB when I do this:
datetick('x', 'yyyy');
I get the year as 0117 instead of 2017?
0 件のコメント
回答 (1 件)
per isakson
2019 年 6 月 29 日
編集済み: per isakson
2019 年 6 月 29 日
That's most likely because 42931.00 is an Excel date number, not a Matlab date number.
4 件のコメント
Walter Roberson
2019 年 6 月 29 日
date is a function that returns a single character vector, that datetime then converts into a single datetime object. If you plot with that as your only data point then MATLAB invents start and end times.
参考
カテゴリ
Help Center および File Exchange で Annotations についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!