Search code examples
matlabfontspublishfigure

Publication ready figures-Matlab


I want to create high-quality figures ready to be submitted for publication. What is the best font size, type of file to be saved as(.fig, .eps, .png?) and generally the characteristics required for a top-quality figure?


Solution

  • Depends on the paper editing software you use.

    If you use Latex or Overleaf, exporting to PDF is the easiest/simplest/smallest-file-size one while keeping image quality as high as possible (i.e. vector format). My typical workflow is

    1. create the plot, set font size to 18 o 20 use set(gca,'fontsize',..).
    2. set(gcf,'paperpositionmode','auto'); this is important! it makes your figure what-you-see-is-what-you-get, so you can adjust figure sizes relative to the font size.
    3. save as PDF or print -dpdf to export to the figure.
    4. call pdfcrop yourfigure.pdf to remove the margins, pdfcrop is available on Linux/Mac, but also available on Windows. If you can't install pdfcrop, you can also use inkscape to fit plot to page.
    5. I usually try to make the figure in its final look using matlab commands (so it can be easily reproduced), but in case there are changes that I can;t make automatically, I will open the pdf using inkscape and manually edit.
    6. if the figure is a 3D surface/mesh rendering with transparency, I will directly call print -dpng -r300 myfile.png to create a png bitmap image directly. Exporting to pdf generates huge file sizes and slow rendering.
    7. once done, upload the pdf or png to overleaf, the platform accepts these formats directly.

    If using older versions of MS Word, I had been exporting images to EPS and insert to keep the images in highest quality possible. However, since 2017, this feature was turned off

    https://support.microsoft.com/en-gb/office/support-for-eps-images-has-been-turned-off-in-office-a069d664-4bcf-415e-a1b5-cbb0c334a840

    but one can still modify a registry key to turn it on.

    Later MS Office accepts svg, which you can export from matlab.