Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I've just started using GNUplot to create graphs. I've been using the epslatex terminal and my issue is, when I create my graph in the wxt terminal, and then replot it in the epslatex terminal, the linestyle changes, even if I never explicitly specified a linestyle. Basically, in the wxt terminal, then curve is solid; however, in the epslatex terminal, the curve is dashed.

I read somewhere that changing terminals can give different linestlyes, and that one is supposed to issue the command 'test' to see the various styles; however, when I try to do 'test' in the epslatex terminal, it tells me that "epslatex terminal cannot write to standard output" (which makes sense I guess). I'm just wondering where I can find what the different linestlyes correspond to in the epslatex terminal.

Also, as a bit of a sub-question, I'm wondering if my approach is any good... To create the graphs, I create it the epslatex terminal, then I convert the eps file to a pdf file so that I can use pdflatex. Is there a better way to do this (perhaps GNUplot can create the pdf for me)?

share|improve this question
5  
I would recommend using PGFPlots, which is a LaTeX package that creates plots directly within your document. It can use gnuplot as a backend, so you have all the power of gnuplot, but you get a much tighter integration with your documents (the same font is used automatically, for example) and a leaner workflow (you don't need to change to a different program to generate your plots). See tex.stackexchange.com/questions/58900/… or tex.stackexchange.com/questions/41666/…, for example –  Jake Oct 31 '12 at 8:04
add comment

1 Answer

up vote 6 down vote accepted

To use the epslatex terminal with the test command, you first need to specify where to write the output. You can do that by issuing set out "<filename>.tex, then test, and then set out to close the file. You'll then get a <filename>.tex and a <filename>.eps. By using \input{<filename>} in a LaTeX document, you'll get the following output (assuming you used set terminal epslatex color):

As you can see, the epslatex terminal uses dashed line styles by default. You can change to solid colored lines by using set terminal epslatex color solid:


For comparison, here's the wxt output:

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.