1. |
Have a file named .gnuplot
placed in the
root directory containing some convenient permanent directives, such as:
set
terminal pbm medium color
set output "gnu.out"
set data style lines
set nokey
set time
set size 0.85,0.85 |
(Plot will be of type "pbm" with these characteristics.)
(Sets the name of the file, gnu.out, to be created.)
(The plot will have a "line" —or "points", "dots", etc..)
(Suppresses the "key" or legend.)
(Creation time will be shown on plot.)
(Plot will be this fraction of its normal size.) |
|
2. |
Produce a file, say
gnudata.txt, with 2 (or more) columns of numbers, x
and y (possibly interspersed with comment lines, beginning with
#): |
#My data are: |
2.4 3.0 5.5 7.1 … |
3.12 4.40 6.80 11.00 … |
|
3. |
Run gnuplot. At its prompt,
execute plot "gnudata.txt" (as per 2.), and quit with
the command quit (or simply q). The
output file gnu.out (as per 1.) has been
created. (This is a "pbm", portable bitmap, file, needing
conversion to, say "gif".)
|
4. |
To convert gnu.out (as per
3.) to a gif file, say gnu.gif, execute at
least the first Unix command:
/usr/local/bin/netpbm/ppmtogif gnu.out > gnu.gif
rm -f gnu.out
The file gnu.gif has been created.
( a) Indeed,
"pbm" and "ppm" are right. b) Conversion to gif
files is the only one available.)
|
5. |
Suggestions Work is
easier with eps (encapsulated postscript) and a
script, say gnuload:
• In .gnuplot, use appropriately 'set terminal
postscript eps enhanced "Times-New-Roman" 32', 'set output "gnu.eps"',
'set size 1.0,1.0'.
• Create two files, gnuload.txt and
(in the path) gnuload, respectively, containing the
following, and execute the batch command gnuload:
[gnuload.txt] open "gnudata.txt"
[gnuload]
gnuplot .../bin/gnuload.txt
The file gnu.eps has been created.
|
|