Recently updated to Matlab 2014b, now figures default to plotting off screen, axes dimensions are wrong
2 次查看(过去 30 天)
显示 更早的评论
Hello,
Sorry if I'm asking in the wrong spot, but I recently updated from 2012a to 2014b, and now I'm starting to experience a whole bunch of problems with my plots. As the title says, it's defaulting to plotting all my figures offscreen, which in itself isn't a huge problem but it's also making the window incredibly large, but the axes are basically not viewable at all. I believe this is related to the code I have running in my start up
set(0,'DefaultFigurePaperPositionMode','auto');
set(0,'DefaultFigureUnits','inches');
set(0,'DefaultFigurePaperUnits','inches');
set(0,'DefaultAxesUnits','inches');
I can disable this code, and then the figures will plot up on screen and at normal sizes, but I have the start up set this way so that the plots won't resize if I resize my window and was really hoping to not change that.
Now I can set the DefaultFigurePosition in my start up so it fixes part of the issue, but what I'm really having trouble with is setting the default axes so that it doesn't make the figure impossible to view. Here's a link to an image of what the figure ends up looking like.
I was wondering if anyone had any advice for something I could add to my start up that would help fix this issue. Thank you in advance to anyone who takes the time to reply.
-Phil
2 个评论
Rich Ohman
2015-4-8
The issue with the Axes position is a bug in R2014b and is fixed in R2015a.
For now, you could try setting both the Figure and Axes default positions to what they would be for the inches conversion:
set(0,'defaultFigurePosition', [7.0729 7.0521 5.8333 4.3750]);
set(0,'defaultAxesPosition', [0.7583 0.4813 4.5208 3.5656]);
set(0,'DefaultFigurePaperPositionMode','auto');
set(0,'DefaultFigureUnits','inches');
set(0,'DefaultFigurePaperUnits','inches');
set(0,'DefaultAxesUnits','inches');
-Rich
Adam
2015-4-8
I don't think it will make any difference at all to the behaviour you are seeing, but you should use e.g.
set( groot, 'defaultFigurePosition',...)
from R2014b rather than
set( 0, 'defaultFigurePosition',... )
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Annotations 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!