This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

Printing and Saving

Print and export to standard file formats


printPrint figure or save to specific file format
saveasSave figure to specific file format
getframeCapture axes or figure as movie frame
savefigSave figure and contents to FIG-file
openfigOpen figure saved in FIG-file
orientPaper orientation for printing or saving
hgexportExport figure
printoptConfigure printer defaults


Print Figure from File Menu

This example shows how to print a figure, preserve the background color, and control the printed figure size.

Copy Figure to Clipboard from Edit Menu

This example shows how to copy a figure to the clipboard and how to set copy options.

Save Plot as Image or Vector Graphics File

This example shows how to save plots to a specific file format.

Save Figure to Reopen in MATLAB Later

This example shows how to save a figure so that you can reopen it in MATLAB® later.

Customize Figure Before Saving

This example shows how to use the Export Setup window to customize a figure before saving it.

Save Figure at Specific Size and Resolution

This example shows how to control the dimensions of printed or saved figures.

Save Plot with Minimal White Space

This example shows how to save a figure so that the saved figure has a tight margin of white space around the axes.

Save Figure Preserving Background Color

This example shows how to ensure that the colors of the saved figure match the colors on the display.

Save Axes Without Saving UI Controls

To save only the axes from a figure that has uicontrols, you can use print with the '-noui' option.