mercredi 12 mai 2021

Saving Matplotlib graphs with LaTeX fonts as eps

I am trying to make publication-quality in Jupyter-lab using matplotlib and LaTeX fonts. I have created a simple document following instructions found here: https://matplotlib.org/stable/tutorials/text/usetex.html

The graph was created with beautiful fonts; however, saved eps file was blank. The same graph could be successfully saved as png, but it looked blurry when import to LaTeX even using dpi=2400 option. Eps files WITHOUT LaTeX fonts were sharp as a razor when imported into LaTeX file.

Suggestions? Workarounds?

Thanks, Radovan

PS. One workaround I found was using gnuplot and cairolatex terminal ... resulting *.tex file could be compiled with Pdflatex with excellent results. But that a different story :-).

Aucun commentaire:

Enregistrer un commentaire