saveTightFigure(h,o​utfilename)

Get rid of the white margin in saveas output (update : w/o change the printed figure)
329 Downloads
Updated 26 Dec 2014

View License

MATLAB's saveas pads your figure with a white margin. This m-file is prevents that.
Exellent to save pdf figures without the white margin (to include in LaTeX reports for example).
Updated version of saveTightFigure (by E Akbas). E Akbas Fuction change the ploted fuction and after that we was unable to resize the ploted figure. This update allow you to use this function like the saveas fuction.
With this version the figure is copied, changed and saved.

Cite As

Flavio "LeviCC" Capitao (2024). saveTightFigure(h,outfilename) (https://www.mathworks.com/matlabcentral/fileexchange/48877-savetightfigure-h-outfilename), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2013a
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Printing and Saving in Help Center and MATLAB Answers

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes
1.1.0.0

(image update)

1.0.0.0