1

I make plots using gnuplot by

set term postscript eps color blacktext "Helvetica" 24
set output "filename.eps"

However, when I include the eps file in latex file, the quality of eps is not satisfactory.

I have also searched google a lot and saw some sites such as http://www.cs.cityu.edu.hk/~tanrui/eps.html, however, my figures are more complicated that theirs and hence their commands don't help me fully. I also checked GNUPLOT: Trying to increase the quality but my figures are eps, not pdf.

Can someone tell, how to improve the quality of figures.

Community
  • 1
  • 1
user984260
  • 3,401
  • 5
  • 25
  • 38
  • 2
    Is the quality unsatisfactory as an eps file already or only in the final, Latex-compiled document. Please specify what exactly the problem is. – simmmons Aug 09 '12 at 14:06
  • Thanks. After inclusion into latex, the quality is not good: fine details seem to be lost. On seeing eps itself with evince, it looks fine. – user984260 Aug 09 '12 at 15:02
  • 1
    How are you compiling the latex? Are you using `pdflatex` or regular `latex`? – mgilson Aug 10 '12 at 02:27
  • I used latex to compile. – user984260 Aug 10 '12 at 15:28
  • Then are you viewing the output `dvi` or using some other tool to convert to postscript or pdf? – mgilson Aug 11 '12 at 20:21
  • @mgilson Yes, I am converting dvi to pdf using dvipdf tool. Are there any settings to be taken care of or a better alternative. I would be grateful for the answer. – user984260 Aug 12 '12 at 12:18
  • 1
    Maybe it's a problem of the pdf-viewer (i.e. the interpreter of the vector-graphic). I also use dvipdf together with gnuplot/latex and did not see any lost of quality – Raphael Roth Aug 13 '12 at 08:58

2 Answers2

2

you can try to increase the output resolution, for example:

set term postscript eps size 1024, 720 color blacktext "Helvetica" 24

Then use maximum figure width in latex

includegraphics[width = \paperwidth]{yourfigurefilepath}
hmitcs
  • 343
  • 4
  • 11
  • 1
    That uses a size of 1024 x 720 inches! I guess this is a bit big. And there is no such thing as resolution for a vector-based output format like EPS. Furthermore, you should use the output size which you'll need later. Otherwise you will get different scalings for different images and the font sizes differs from image to image... – Christoph Jan 10 '14 at 18:25
-2

I think this answear might help: https://stackoverflow.com/a/7584726/2584653 (you just need to use "eps" instead of "png" for the final file). Actually this is something I usually use.

Community
  • 1
  • 1
  • 5
    Please provide code examples or more substance to your answer than simply linking to another question. We love having new users on the site, so please check out [how to answer](http://stackoverflow.com/help/how-to-answer) and other articles in the help center to improve your answer, and the site as a whole! – Singular1ty Aug 02 '15 at 23:07