Next: , Previous: gpic, Up: complete_list_of_terminals


4.1.0.28 gpic

The `gpic` terminal driver generates GPIC graphs in the Free Software Foundations's "groff" package. The default size is 5 x 3 inches. The only option is the origin, which defaults to (0,0).

Syntax:

           set terminal gpic {<x> <y>}
     

where `x` and `y` are in inches.

A simple graph can be formatted using

           groff -p -mpic -Tps file.pic > file.ps.
     

The output from pic can be pipe-lined into eqn, so it is possible to put complex functions in a graph with the `set label` and `set {x/y}label` commands. For instance,

           set ylab '@space 0 int from 0 to x alpha ( t ) roman d t@'
     

will label the y axis with a nice integral if formatted with the command:

           gpic filename.pic | geqn -d@@ -Tps | groff -m[macro-package] -Tps
               > filename.ps
     

Figures made this way can be scaled to fit into a document. The pic language is easy to understand, so the graphs can be edited by hand if need be. All co-ordinates in the pic-file produced by `gnuplot` are given as x+gnuplotx and y+gnuploty. By default x and y are given the value 0. If this line is removed with an editor in a number of files, one can put several graphs in one figure like this (default size is 5.0x3.0 inches):

           .PS 8.0
           x=0;y=3
           copy "figa.pic"
           x=5;y=3
           copy "figb.pic"
           x=0;y=0
           copy "figc.pic"
           x=5;y=0
           copy "figd.pic"
           .PE
     

This will produce an 8-inch-wide figure with four graphs in two rows on top of each other.

One can also achieve the same thing by the command

           set terminal gpic x y
     

for example, using

           .PS 6.0
           copy "trig.pic"
           .PE"