I have the following gnuplot plot embedded in my Latex document:
\begin{gnuplot}[terminal=epslatex,terminaloptions={color size 14.5cm, 9cm}]
set view map
unset surface
unset key
unset xtics
unset ytics
unset ztics
set contour base
set cntrparam levels discrete 2,4,8,16,32,64,128,256,512
set isosamples 100
splot y**2 + 0.1*x**2 notitle
\end{gnuplot}
The plot is alright. All I want to achive is that the contour lines all have the same style, i.e. line type and the same colour, black if possible.
Thanks for any advices.
I don’t know about the latex terminal, but you could try:
http://www.gnuplot.info/demo/contours.html (see the section where they draw all the contours in the same color — It’s the last example on that page)
EDIT
It looks like the coloring of the contours is controlled by
{un}set clabel. So if you just addunset clabelto your script, then the contours should probably show up black (with thelc rgb "#000000"that I had above. Note thatunset clabelimpliesunset key. To achieve this with the ability to add a key is a little more tricky…in case you ever need to keep the labels…
You’ll likely need to
set term pushto save the current terminal.set term unknownto make the output go nowhere.set table "junk.dat"and then issue your plot commmand as normal. This will write the contours to a file “junk.dat” which can then be splotted with lines after aset term popto restore the old terminal settings (you’ll probably need some variant oftitle columnheadand maybe an index/every as well to get the labels to appear correctly…) — I’m not actually sure if theset term push/popcommands are necessary in this case. Anyway, plotting things to tables with gnuplot is something that I’ve done a number of times for a number of different applications. It’s a great tool to keep in mind.