Hi, I'm having trouble when creating plots for use in latex documents. I tried several methods, but the fonts are always inconsistent in size and weight. I thought the "text.usetex" option to provide a result closest to the latex document I want to include the plots in, but this minimal example shows that there is some weird behavior of matplotlib producing bold fonts by default:
import pylab as p params_text = { 'text.usetex': True, } p.rcParams.update(params_text) X = range(10) Y = [x**2 for x in X] p.plot(X, Y) p.xlabel(ur"$\rm{time}$ \rm{time} time (s $10^3$)") p.show() In a normal latex document, the words within the xlabel should look the same. The "correct" font style seems to be the one within the math mode. Unfortunately the usetex option produces pdf files 10x larger, but without it, the text looks even more distorted. I get best results in terms of appearance and size when producing eps files with the usedistiller xpdf option and then manually convert eps to pdf. But still, the default fonts are too bold although the weight was never altered. -- View this message in context: http://old.nabble.com/Matplotlib-in-Latex-documents-tp33746279p33746279.html Sent from the matplotlib - users mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users