how to save figures without margin?
21 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
Jack Xiao
am 11 Mai 2019
Kommentiert: Nick Tsui
am 17 Nov. 2022
as the title, I need to save the figures or images shown in the figure with the same size of the image.
but there are always margins as shown in the following: (the size is 604x593)
![捕获asda.PNG](https://www.mathworks.com/matlabcentral/answers/uploaded_files/218942/%E6%8D%95%E8%8E%B7asda.png)
the orginal image is : (the size is 500x430)
![ILSVRC2012_val_00000224.JPEG](https://www.mathworks.com/matlabcentral/answers/uploaded_files/218943/ILSVRC2012_val_00000224.jpeg)
how to save figures without margin?
0 Kommentare
Akzeptierte Antwort
Valeriy
am 23 Feb. 2020
Try:
axis off; % If you have axis titles, labels, etc.
set (gca,'Position',[0 0 1 1]);
print(gcf,'Test.jpg', '-djpeg', '-r300');
2 Kommentare
Weitere Antworten (0)
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!