How can I save only content of matlab figure ?
43 次查看(过去 30 天)
显示 更早的评论
i am using the following code: fig=figure,imshow(RIm); saveas(fig,'22.jpg');
It saves as image but with white border. How can I save only content of the figure.
0 个评论
回答(2 个)
KSSV
2017-2-8
x = rand(20,1) ;
y = rand(20,1) ;
plot(x,y)
set(gca,'LooseInset',get(gca,'TightInset'));
saveas(gcf,'junk.jpg')
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Subplots 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!