Graphics    

Setting the Resolution

Resolution refers to how accurately your figure is rendered when printed or exported. Higher resolutions produce higher quality output. The specific definition of resolution depends on whether your figure is output as a bitmap or as a vector graphic.

You can change the resolution that MATLAB uses to print a figure

Default Resolution and When You Can Change It

The default resolution depends on the renderer used and the graphics format or printer driver specified. The following two tables summarize the default resolutions and whether you can change them.

Resolutions Used with Graphics Formats
Graphics Format
Default Resolution
Can Be Changed?
Built-in MATLAB export formats, (except for EMF, EPS, and ILL)
150 dpi (always use OpenGL or Z-buffer)
Yes
EMF export format (Enhanced Metafile)
150 dpi
Yes
EPS (Encapsulated PostScript)
150 dpi, if OpenGL or Z-buffer;
864 dpi if Painter's
Yes
ILL export format (Adobe Illustrator)
72 dpi (always uses Painter's)
No
Ghostscript export formats
72 dpi (always uses OpenGL or Z-buffer)
No


Resolutions Used with Printer Drivers
Printer Driver
Default Resolution
Can Be Changed?
Windows and PostScript drivers
150 dpi, if OpenGL or Z-buffer; 864 dpi if Painter's
Yes
Ghostscript driver
150 dpi, if OpenGL or Z-buffer; 864 dpi if Painter's
Yes
HPGL driver
1116 dpi (always uses Painter's)
Yes

Choosing a Setting

You may need to determine your resolution requirements through experimentation, but you can also use the following guidelines.

For Printing.   The default resolution of 150 dpi is normally adequate for typical laser-printer output. However, if you are preparing figures for high-quality printing, such as a textbook or color brochures, you may want to use 200 or 300 dpi. The resolution you can use may be limited by the printer's capabilities.

For Exporting.   If you are exporting your figure, base your decision on the resolution supported by the final output device. For example, if you will import your figure into a word processing document and print it on a printer that supports a maximum resolution setting of 300 dpi, you may want to export your figure using 300 dpi to get a precise one-to-one correspondence between pixels in the file and dots on the paper.

Impact of Resolution on Size and Memory Needed

Resolution affects file size and memory requirements. For both printing and exporting, the higher the resolution setting, the longer it takes for MATLAB or your printer to render your figure.

Using the Graphical User Interface on Windows

To set the resolution for built-in MATLAB printer drivers on Windows systems,

  1. From the Print dialog box, click Properties. This opens a new dialog box that may differ from one printer to another.
  2. You may be able to set the resolution from this dialog, or you may have to click on Advanced to get to a dialog box that enables you to do this.
  3. Set the resolution, and then click OK. (The resolution setting may be labeled by another name, such as "Print Quality.")

Using the Graphical User Interface on UNIX

To set the resolution for built-in MATLAB printer drivers on UNIX systems,

  1. From the UNIX Print dialog box, click Options. This opens the Printing Options dialog box.
  2. Under the Printing Resolution panel, select either Use same resolution as the screen or Specify resolution in dots per inch.
  3. If you select Specify resolution in dots per inch, enter a value in the Specify resolution in dots per inch text box.
  4. Click OK.

Using MATLAB Commands

If you use a Windows printer driver, you can only set the resolution using the Windows Document Properties dialog box.

Otherwise, to set the resolution for printing or exporting, the syntax is

where number is the number of dots per inch. To print or export a figure using screen resolution, set number to 0 (zero).

This example prints the current figure with a resolution of 100 dpi,

This example exports the current figure to a TIFF file using screen resolution,


  Selecting a Renderer Setting the Axes Ticks and Limits