
- •Copyright
- •Introduction
- •Seeking-assistance
- •New features
- •New syntax
- •Local customization of linetypes
- •New plot styles
- •Revised polar axes
- •New smoothing algorithms
- •New time/date handling
- •Statistical summary of data
- •New or revised terminal drivers
- •Backwards compatibility
- •Batch/Interactive Operation
- •Canvas size
- •Command-line-editing
- •Comments
- •Coordinates
- •Datastrings
- •Enhanced text mode
- •Environment
- •Expressions
- •Functions
- •Elliptic integrals
- •Random number generator
- •Value
- •Operators
- •Unary
- •Binary
- •Ternary
- •Summation
- •Fonts
- •Cairo (pdfcairo, pngcairo, epscairo, wxt terminals)
- •Gd (png, gif, jpeg terminals)
- •Postscript (also encapsulated postscript *.eps)
- •Glossary
- •Linetypes, colors, and styles
- •Colorspec
- •Linecolor variable
- •Rgbcolor variable
- •Linestyles vs linetypes
- •Mouse input
- •Bind
- •Bind space
- •Mouse variables
- •Plotting
- •Start-up (initialization)
- •String constants and string variables
- •Substitution and Command line macros
- •Substitution of system commands in backquotes
- •Substitution of string variables as macros
- •String variables, macros, and command line substitution
- •Syntax
- •Quote Marks
- •Time/Date data
- •Boxerrorbars
- •Boxes
- •Boxplot
- •Boxxyerrorbars
- •Candlesticks
- •Circles
- •Ellipses
- •Dots
- •Filledcurves
- •Financebars
- •Fsteps
- •Fillsteps
- •Histeps
- •Histograms
- •Newhistogram
- •Automated iteration over multiple columns
- •Image
- •Transparency
- •Image failsafe
- •Impulses
- •Labels
- •Lines
- •Linespoints
- •Points
- •Polar
- •Steps
- •Rgbalpha
- •Rgbimage
- •Vectors
- •Xerrorbars
- •Xyerrorbars
- •Yerrorbars
- •Xerrorlines
- •Xyerrorlines
- •Yerrorlines
- •3D (surface) plots
- •2D projection (set view map)
- •Call
- •Clear
- •Evaluate
- •Exit
- •Adjustable parameters
- •Short introduction
- •Error estimates
- •Statistical overview
- •Practical guidelines
- •Control
- •Control variables
- •Environment variables
- •Multi-branch
- •Starting values
- •Tips
- •Help
- •History
- •Iteration
- •Load
- •Lower
- •Pause
- •Plot
- •Axes
- •Binary
- •General
- •Array
- •Record
- •Skip
- •Format
- •Endian
- •Filetype
- •Keywords
- •Data
- •Every
- •Index
- •Smooth
- •Thru
- •Using
- •Volatile
- •Errorbars
- •Errorlines
- •Functions
- •Parametric
- •Ranges
- •Iteration
- •Title
- •With
- •Quit
- •Raise
- •Refresh
- •Replot
- •Reread
- •Reset
- •Save
- •Set-show
- •Angles
- •Arrow
- •Autoscale
- •Parametric mode
- •Polar mode
- •Bars
- •Bind
- •Bmargin
- •Border
- •Boxwidth
- •Clabel
- •Clip
- •Cntrparam
- •Color box
- •Colornames
- •Contour
- •Data style
- •Decimalsign
- •Dgrid3d
- •Dummy
- •Encoding
- •Fontpath
- •Format
- •Gprintf
- •Function style
- •Functions
- •Grid
- •Hidden3d
- •Historysize
- •Isosamples
- •Key placement
- •Key samples
- •Label
- •Linetype
- •Lmargin
- •Loadpath
- •Locale
- •Logscale
- •Macros
- •Mapping
- •Margin
- •Mouse
- •Doubleclick
- •Mouseformat
- •Scrolling
- •X11 mouse
- •Zoom
- •Multiplot
- •Mx2tics
- •Mxtics
- •My2tics
- •Mytics
- •Mztics
- •Object
- •Rectangle
- •Ellipse
- •Circle
- •Polygon
- •Origin
- •Output
- •Parametric
- •Plot
- •Algorithm
- •Position
- •Scanorder
- •Clipping
- •Hidden3d
- •Interpolate
- •Palette
- •Rgbformulae
- •Functions
- •Cubehelix
- •File
- •Gamma correction
- •Postscript
- •Pointintervalbox
- •Pointsize
- •Polar
- •Psdir
- •Raxis
- •Rmargin
- •Rrange
- •Rtics
- •Samples
- •Size
- •Style
- •Set style arrow
- •Boxplot
- •Set style data
- •Set style function
- •Set style increment
- •Set style line
- •Set style circle
- •Set style rectangle
- •Set style ellipse
- •Surface
- •Table
- •Terminal
- •Termoption
- •Tics
- •Ticslevel
- •Ticscale
- •Timestamp
- •Timefmt
- •Title
- •Tmargin
- •Trange
- •Urange
- •Variables
- •Version
- •View
- •Vrange
- •X2data
- •X2dtics
- •X2label
- •X2mtics
- •X2range
- •X2tics
- •X2zeroaxis
- •Xdata
- •Xdtics
- •Xlabel
- •Xmtics
- •Xrange
- •Xtics
- •Xtics rangelimited
- •Xyplane
- •Xzeroaxis
- •Y2data
- •Y2dtics
- •Y2label
- •Y2mtics
- •Y2range
- •Y2tics
- •Y2zeroaxis
- •Ydata
- •Ydtics
- •Ylabel
- •Ymtics
- •Yrange
- •Ytics
- •Yzeroaxis
- •Zdata
- •Zdtics
- •Zzeroaxis
- •Cbdata
- •Cbdtics
- •Zero
- •Zeroaxis
- •Zlabel
- •Zmtics
- •Zrange
- •Ztics
- •Cblabel
- •Cbmtics
- •Cbrange
- •Cbtics
- •Shell
- •Splot
- •Matrix
- •Grid data
- •Splot surfaces
- •Stats (Statistical Summary)
- •System
- •Test
- •Unset
- •Update
- •While
- •Complete list of terminals
- •Aifm
- •Aqua
- •Cairolatex
- •Canvas
- •Cgm font
- •Cgm fontsize
- •Cgm linewidth
- •Cgm rotate
- •Cgm solid
- •Cgm size
- •Cgm width
- •Cgm nofontlist
- •Context
- •Requirements
- •Calling gnuplot from ConTeXt
- •Corel
- •Debug
- •Dumb
- •Eepic
- •Emxvga
- •Epscairo
- •Epslatex
- •Excl
- •Examples
- •Gpic
- •Grass
- •Hpgl
- •Hpljii
- •Hppj
- •Imagen
- •Jpeg
- •Latex
- •Linux
- •Lua tikz
- •Macintosh
- •METAFONT Instructions
- •Metapost Instructions
- •Next
- •Openstep (next)
- •Pdfcairo
- •Examples
- •Pngcairo
- •Postscript
- •Editing postscript
- •Postscript prologue
- •Postscript adobeglyphnames
- •Pslatex and pstex
- •Pstricks
- •Regis
- •Svga
- •Texdraw
- •Tgif
- •Tikz
- •Tkcanvas
- •Tpic
- •Vgagl
- •Windows
- •Graph-menu
- •Printing
- •Text-menu
- •Wgnuplot.mnu
- •Wgnuplot.ini
- •Xlib
- •Known limitations
- •External libraries

gnuplot 4.6 |
177 |
pixels o . More elaborate on/o patterns can be speci ed with a four-digit value. For example, '4441' is four on, four o , four on, one o . The default values shown below are for monochrome displays or monochrome rendering on color or grayscale displays. For color displays, the default for each is 0 (solid line) except for axisDashes which defaults to a '16' dotted line.
gnuplot*borderDashes: 0 gnuplot*axisDashes: 16 gnuplot*line1Dashes: 0 gnuplot*line2Dashes: 42 gnuplot*line3Dashes: 13 gnuplot*line4Dashes: 44 gnuplot*line5Dashes: 15 gnuplot*line6Dashes: 4441 gnuplot*line7Dashes: 42 gnuplot*line8Dashes: 13
Cairolatex
The cairolatex terminal device generates encapsulated PostScript (*.eps) or PDF output using the cairo and pango support libraries and uses LaTeX for text output using the same routines as the epslatex terminal.
Syntax:
set terminal cairolatex {eps | pdf}
{standalone | input}
{blacktext | colortext | colourtext} {header <header> | noheader} {mono|color} {solid|dashed}
{{no}transparent} {{no}crop} {background <rgbcolor>} {font <font>} {fontscale <scale>}
{linewidth <lw>} {rounded|butt} {dashlength <dl>} {size <XX>{unit},<YY>{unit}}
The cairolatex terminal prints a plot like terminal epscairo or terminal pdfcairo but transfers the texts to LaTeX instead of including them in the graph. For reference of options not explained here see pdfcairo (p. 207).
eps and pdf select the type of grahics output. Use eps with latex/dvips and pdf for pd atex.
blacktext forces all text to be written in black even in color mode;
The cairolatex driver o ers a special way of controlling text positioning: (a) If any text string begins with 'f', you also need to include a 'g' at the end of the text, and the whole text will be centered both horizontally and vertically by LaTeX. (b) If the text string begins with '[', you need to continue it with: a position speci cation (up to two out of t,b,l,r,c), ']f', the text itself, and nally, 'g'. The text itself may be anything LaTeX can typeset as an LR-box. nrulefgfg's may help for best positioning. See also the documentation for the pslatex (p. 214) terminal driver. To create multiline labels, use nshortstack, for example
set ylabel '[r]{\shortstack{first line \\ second line}}'
The back option of set label commands is handled slightly di erent than in other terminals. Labels using 'back' are printed behind all other elements of the plot while labels using 'front' are printed above everything else.
The driver produces two di erent les, one for the eps or pdf part of the gure and one for the LaTeX part. The name of the LaTeX le is taken from the set output command. The name of the eps/pdf le is derived by replacing the le extension (normally '.tex') with '.eps' or '.pdf' instead. There is no LaTeX output if no output le is given! Remember to close the output le before next plot unless in multiplot mode.
In your LaTeX documents use 'ninputf lenameg' to include the gure. The '.eps' or '.pdf' le is included by the command nincludegraphicsf...g, so you must also include nusepackagefgraphicxg in the LaTeX preamble.
178 |
gnuplot 4.6 |
If you want to use coloured text (option colourtext) you also have to include nusepackagefcolorg in the LaTeX preamble.
The behaviour concerning font selection depends on the header mode. In all cases, the given font size is used for the calculation of proper spacing. When not using the standalone mode the actual LaTeX font and font size at the point of inclusion is taken, so use LaTeX commands for changing fonts. If you use e.g. 12pt as font size for your LaTeX document, use '", 12"' as options. The font name is ignored. If using standalone the given font and font size are used, see below for a detailed description.
If text is printed coloured is controlled by the TeX booleans nifGPcolor and nifGPblacktext. Only if nifGPcolor is true and nifGPblacktext is false, text is printed coloured. You may either change them in the generated TeX le or provide them globally in your TeX le, for example by using
\newif\ifGPblacktext
\GPblacktexttrue
in the preamble of your document. The local assignment is only done if no global value is given.
When using the cairolatex terminal give the name of the TeX le in the set output command including thele extension (normally ".tex"). The graph lename is generated by replacing the extension.
If using the standalone mode a complete LaTeX header is added to the LaTeX le; and "-inc" is added to the lename of the gaph le. The standalone mode generates a TeX le that produces output with the correct size when using dvips, pdfTeX, or VTeX. The default, input, generates a le that has to be included into a LaTeX document using the ninput command.
If a font other than "" or "default" is given it is interpreted as LaTeX font name. It contains up to three parts, separated by a comma: 'fontname,fontseries,fontshape'. If the default fontshape or fontseries are requested, they can be omitted. Thus, the real syntax for the fontname is 'ffontnamegf,fontseriesgf,fontshapeg'. The naming convention for all parts is given by the LaTeX font scheme. The fontname is 3 to 4 characters long and is built as follows: One character for the font vendor, two characters for the name of the font, and optionally one additional character for special fonts, e.g., 'j' for fonts with old-style numerals or 'x' for expert fonts. The names of many fonts is described in
http://www.tug.org/fontname/fontname.pdf
For example, 'cmr' stands for Computer Modern Roman, 'ptm' for Times-Roman, and 'phv' for Helvetica. The font series denotes the thickness of the glyphs, in most cases 'm' for normal ("medium") and 'bx' or 'b' for bold fonts. The font shape is 'n' for upright, 'it' for italics, 'sl' for slanted, or 'sc' for small caps, in general. Some fonts may provide di erent font series or shapes.
Examples:
Use Times-Roman boldface (with the same shape as in the surrounding text):
set terminal cairolatex font 'ptm,bx'
Use Helvetica, boldface, italics:
set terminal cairolatex font 'phv,bx,it'
Continue to use the surrounding font in slanted shape:
set terminal cairolatex font ',,sl'
Use small capitals:
set terminal cairolatex font ',,sc'
By this method, only text fonts are changed. If you also want to change the math fonts you have to use the "gnuplot.cfg" le or the header option, described below.
In standalone mode, the font size is taken from the given font size in the set terminal command. To be able to use a speci ed font size, a le "size<size>.clo" has to reside in the LaTeX search path. By default, 10pt, 11pt, and 12pt are supported. If the package "extsizes" is installed, 8pt, 9pt, 14pt, 17pt, and 20pt are added.
The header option takes a string as argument. This string is written into the generated LaTeX le. If using the standalone mode, it is written into the preamble, directly before the nbeginfdocumentg command. In