After hours of debugging I finally updated to the newest release of export_fig (v 2.0.0.0). Issue resolved. Needless to say I feel a bit stupid.
Issue with datetime and export_fig
13 ビュー (過去 30 日間)
古いコメントを表示
For years I've never had any issues with datetime nor export_fig. However, today I noticed some erroneous datetime labels after exporting by export_fig. After hours of debugging, I was able to reproduce the issue by these lines of code:
td=datetime(2009:2016,1,2)
plot(td,td)
export_fig(1,'myfig','-png')
Basically the resulting image has different XTickLabels than what I see on the screen prior to exporting. The erroneous labels briefly appear the screen during the export but revert back to the correct ones after a few seconds. Interestingly enough, I do not get this issue if I change the days input to 1 instead of 2 in datetime, probably because the XTicks are exactly aligned with my data (?).
I can use print just fine, it's just export_fig that's being annoying. I am wondering:
- Is it reproducible or is related to my local settings?
- Does anyone know the cause?
- Does anyone know a fix?
The attached images were exported by print and export_fig, respectively.
0 件のコメント
回答 (1 件)
参考
カテゴリ
Help Center および File Exchange で Data Type Identification についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!