Change Jpeg Aspect Ratio with hgexport
1 次查看(过去 30 天)
显示 更早的评论
I have a figure with a bunch of subplots (see attachment) which I want to export as jpg with hgexport. I want to fit it nicely to A4-format but somehow the aspect ratio just wont change. Even if I try to put it out squared (100cm*100cm) the jpg-image still has unchanged width:height of about 2:1 (jpg attached too for reference). The 2:1 ratio is best seen when sending the jpg to printer with windows photo displayer. My options for hgexport are:
options.Format='jpeg';
options.Width = 100;
options.Height = 100;
options.Units = 'centimeters';
options.Resolution = 600;
options.ScaledFontSize = 0.5;
options.LineMode = 'fixed';
And later I call it with:
hgexport(figure_handle,filename,options);
But as said above it always throws out the jpg at about 2:1. I have also tried to change the export setup in the file-menu just to make sure it does not override. No difference either. If I put in 6 rows of plots instead of 4 theres no difference in the aspect ratio the plots are just being squeezed heightwise.
thx for any help
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Subplots 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!