Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Graphics > Gnuplot interactive function plotter > Re: Italic labe...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 8 of 8 Topic 3536 of 3631
Post > Topic >>

Re: Italic labels

by Christoph Bersch <usenet@[EMAIL PROTECTED] > Oct 10, 2008 at 08:57 PM

Dieter Britz wrote:
> 
> I tried this out, using the now modified script new3, as attached,
> which uses the data file grid.dat, also attached. It produces two
> new files, new3.eps (just the grids) and new3.tex. When I then type
> in, translating from your line,
> 
> gnuplot new3.gp && latex new3.gp && dvips new3.dvi
> 
> I get the complaint, reasonably enough, that new3.gp does not exist.
> What am I missing?

It was an error in my commandline. You should run latex on the file
new3.tex

> Gnuplot didn't like the option standalone. Does this mean that my
> gnuplot is out of date? It says it is
> 
> Version 4.0 patchlevel 0
>         last modified Thu Apr 15 14:44:22 CEST 2004
>         System: Linux 2.6.18.2-34-default

Well, it is not really a problem, but with the 'standalone' option it is
less work ;-)
Without this option you must create a second .tex file which includes
the file generated with gnuplot.
Note, that with the epslatex terminal you cannot use the enhanced option
of postscript driver -> '{/=25 ...}' because all the text is typeset
with LaTeX. Every backslash of the LaTeX macros must be escaped to
appear correctly in the output -> set label "$\\Gamma$"

Given your datafile 'grid.dat' the following workflow should work:

                                    ,,,
                                   (o o)  File: plot.gp
-------------------------------oOO--(_)--OOo---------------------------
set term epslatex
set output 'plot-inc.tex'
set nokey
#
# Multiplots of the two grid systems:
#
set size square
set multiplot
set origin 0, 0
set size 0.7,0.7
set xrange [0:6.5]
set yrange [0:6.5]
set format x '%g'
set format y '%g'
set lmargin 10
set bmargin 5
set xtics (1, 2, 5)
set label 1 '0' at -0.35,-0.26
set ytics 2, 2, 6
set label 2 '$R$' at 3, -0.9
set label 3 '$Z$' at -1.3, 3
plot 'grid.dat' using 3:4 w l
#
set origin 0.5, 0
set size 0.7, 0.7
set nolabel
set xrange [0:pi/2]
set xtics ("0" 0, "$\\pi/2$" pi/2)
set yrange [0:1]
set lmargin 5
set bmargin 5
set noxtics
set ytics 0, 1, 1
set label 1 '0' at -0.02, -0.07
set label 2 "$\\theta$" at 0.8, -0.1
set label 3 "$\\Gamma$" at -0.18, 0.6

plot 'grid.dat' w l
---------------------- end file --------------------------------------

call this file with gnuplot:

gnuplot plot.gp

This creates two files: plot-inc.eps and plot-inc.tex
As gnuplot 4.0 does not seem to understand the 'standalone' option, you
must create another .tex file which includes the one created from gnuplot:

                                    ,,,
                                   (o o)  File: plot.tex
-------------------------------oOO--(_)--OOo-------------------------
\do***entclass{article}
\usepackage[T1]{fontenc}
\usepackage{cmbright}
\usepackage{graphicx}
\renewcommand{\familydefault}{\sfdefault}
\begin{do***ent}
\input plot-inc
\end{do***ent}
---------------------- end file --------------------------------------


call this with latex and dvips

latex plot.tex && dvips plot.dvi

and you get the desired output file. This gives you a file 'plot.ps'
which bounding box is not correct. A better option, which requires the
package pst-eps.sty, is to use the following file:

                                    ,,,
                                   (o o)  File: plot-enh.tex
-------------------------------oOO--(_)--OOo-------------------------
\do***entclass{article}
\usepackage[T1]{fontenc}
\usepackage{cmbright}
\usepackage{graphicx}
\usepackage{pst-eps}
\renewcommand{\familydefault}{\sfdefault}
\begin{do***ent}
\begin{TeXtoEPS}
\input plot-inc
\end{TeXtoEPS}
\end{do***ent}
---------------------- end file --------------------------------------

and call it with

latex plot-enh.tex && dvips -E plot-enh.dvi -o plot-enh.tmp.eps &&
epstool --copy --bbox --output plot-enh.eps plot-enh.tmp.eps

(on my debian-computer 'epstool' is ****pped with an equally named
package and adjusts the bounding box when call as above. If you don't
have it, plot-enh.tmp.eps already contains the correctly fomatted output
but with incorrect bounding box)

Then you get a nicely typeset EPS-file 'plot-enh.eps' with correct
bounding box.

Hope this guide helps you and does not contain more tpyos ;-)
Christoph
 




 8 Posts in Topic:
Italic labels
Dieter Britz <oldnob@[  2008-10-08 16:29:31 
Re: Italic labels
sfeam <sfeam@[EMAIL PR  2008-10-08 08:42:14 
Re: Italic labels
Dieter Britz <oldnob@[  2008-10-09 09:41:02 
Re: Italic labels
Christoph Bersch <usen  2008-10-09 10:03:07 
Re: Italic labels
Dieter Britz <oldnob@[  2008-10-09 11:09:10 
Re: Italic labels
Christoph Bersch <usen  2008-10-09 11:44:59 
Re: Italic labels
Dieter Britz <oldnob@[  2008-10-10 14:08:02 
Re: Italic labels
Christoph Bersch <usen  2008-10-10 20:57:54 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Thu Dec 4 1:27:04 CST 2008.