home *** CD-ROM | disk | FTP | other *** search
/ ftp.pasteur.org/FAQ/ / ftp-pasteur-org-FAQ.zip / FAQ / graphics / gnuplot-faq < prev    next >
Encoding:
Internet Message Format  |  1997-06-26  |  56.8 KB

  1. Path: senator-bedfellow.mit.edu!bloom-beacon.mit.edu!thetimes.pixel.kodak.com!news.kodak.com!news-pen-16.sprintlink.net!170.48.15.8!newton.hlthsrc.com!news-pen-15.sprintlink.net!news.nysernet.net!news.sprintlink.net!Sprint!151.164.1.5!news1.rcsntx.swbell.net!news.pbi.net!hunter.premier.net!hammer.uoregon.edu!ais.net!howland.erols.net!blackbush.xlink.net!ka.sub.net!rz.uni-karlsruhe.de!not-for-mail
  2. From: ig25@fg70.rz.uni-karlsruhe.de (Thomas Koenig)
  3. Newsgroups: comp.graphics.apps.gnuplot,comp.answers,news.answers
  4. Subject: comp.graphics.apps.gnuplot FAQ (Frequent Answered Questions)
  5. Supersedes: <comp-graphics-gnuplot-faq_862849823@fg70.rz.uni-karlsruhe.de>
  6. Followup-To: comp.graphics.apps.gnuplot
  7. Date: 25 Jun 1997 15:25:39 +0200
  8. Organization: University of Karlsruhe, Germany
  9. Lines: 1346
  10. Approved: news-answers-request@MIT.Edu
  11. Expires: 23 Jul 1997 13:25:36 GMT
  12. Message-ID: <comp-graphics-gnuplot-faq_867245136@fg70.rz.uni-karlsruhe.de>
  13. Reply-To: ig25@rz.uni-karlsruhe.de
  14. NNTP-Posting-Host: fg70.rz.uni-karlsruhe.de
  15. Mime-Version: 1.0
  16. Content-Type: text/plain; charset=iso-8859-1
  17. Content-Transfer-Encoding: 8bit
  18. NNTP-Posting-User: ig25
  19. Summary: This is the FAQ (Frequently Answered Questions) list of the
  20.          comp.graphics.gnuplot newsgroup, which discusses the
  21.          gnuplot program for plotting 2D - and 3D - graphs.
  22. Keywords: computer graphics, gnuplot
  23. Xref: senator-bedfellow.mit.edu comp.graphics.apps.gnuplot:7460 comp.answers:26735 news.answers:105792
  24.  
  25. Archive-name: graphics/gnuplot-faq
  26. Version: Mon Sep 23 04:23:01 CES 1996
  27. Posting-frequency: every 14 days
  28. URL: http://www.uni-karlsruhe.de/~ig25/gnuplot-faq/
  29.  
  30.    comp.graphics.apps.gnuplot
  31.  
  32.         comp.graphics.apps.gnuplot FAQ (Frequent Answered Questions)
  33.  
  34.    This is the FAQ (Frequently Answered Questions) list of the
  35.    comp.graphics.apps.gnuplot newsgroup, which discusses the gnuplot
  36.    program for plotting 2D - and 3D - graphs.
  37.  
  38.    Most of the information in this document came from public discussion
  39.    on comp.graphics.apps.gnuplot; quotations are believed to be in the
  40.    public domain.
  41.  
  42.    If you are reading this via WWW, and you can't access the individual
  43.    pages, please select here, then try again.
  44.  
  45.    Here's a list of the questions. If you are looking for the answer for
  46.    a specific question, look for the string Qx.x: at the beginning of a
  47.    line, with x.x being the question number. Sections in this FAQ are
  48.      * 0. Meta-Questions
  49.      * 1. General Information
  50.      * 2. Setting it up
  51.      * 3. Working with it
  52.      * 4. Wanted features
  53.      * 5. Miscellaneous
  54.      * 6. Making life easier
  55.      * 7. Known problems
  56.      * 8. Credits
  57.  
  58.  
  59. Questions:
  60.  
  61.   Section 0: Meta - Questions
  62.  
  63.      * Q0.1: Where do I get this document?
  64.      * Q0.2: Where do I send comments about this document?
  65.  
  66.   Section 1: General Information
  67.  
  68.      * Q1.1: What is gnuplot?
  69.      * Q1.2: How did it come about and why is it called gnuplot?
  70.      * Q1.3: Does gnuplot have anything to do with the FSF and the
  71.        GNU project?
  72.      * Q1.4: What does gnuplot offer?
  73.      * Q1.5: Is gnuplot suitable for batch processing?
  74.      * Q1.6: Can I run gnuplot on my computer?
  75.  
  76.   Section 2: Setting it up
  77.  
  78.      * Q2.1: What is the current version of gnuplot?
  79.      * Q2.2: Where can I get gnuplot?
  80.      * Q2.3: How do I get gnuplot to compile on my system?
  81.      * Q2.4: What documentation is there, and how do I get it?
  82.  
  83.   Section 3: Working with it
  84.  
  85.      * Q3.1: How do I get help?
  86.      * Q3.2: How do I print out my graphs?
  87.      * Q3.3: How do I include my graphs in <word processor>?
  88.      * Q3.4: How do I post-process a gnuplot graph?
  89.      * Q3.5: How do I change symbol size, line thickness and the
  90.        like?
  91.      * Q3.6: How do I generate plots in GIF format?
  92.  
  93.   Section 4: Wanted features
  94.  
  95.      * Q4.0: What's new in gnuplot 3.6?
  96.      * Q4.1: Does gnuplot have hidden line removal?
  97.      * Q4.2: Does gnuplot support bar-charts/histograms/boxes?
  98.      * Q4.3: Does gnuplot support multiple y-axes on a single plot?
  99.      * Q4.4: Can I put multiple plots on a single page?
  100.      * Q4.5: Can I put both data files and commands into a single
  101.        file?
  102.      * Q4.6: Can I put Greek letters and super/subscripts into my
  103.        labels?
  104.      * Q4.7 Can I do 1:1 scaling of axes?
  105.      * Q4.8: Can I put tic marks for x and y axes into 3d plots?
  106.      * Q4.9: Does gnuplot support a driver for <graphics format>?
  107.      * Q4.10: Can I put different text sizes into my plots?
  108.      * Q4.11: How do I modify gnuplot?
  109.      * Q4.12: How do I skip data points?
  110.  
  111.   Section 5: Miscellaneous
  112.  
  113.      * Q5.1: I've found a bug, what do I do?
  114.      * Q5.2: Can I use gnuplot routines for my own programs?
  115.      * Q5.3: What extensions have people made to gnuplot? Where can I
  116.        get them?
  117.      * Q5.4: Can I do heavy-duty data processing with gnuplot?
  118.      * Q5.5: I have ported gnuplot to another system, or patched it.
  119.        What do I do?
  120.      * Q5.6: I want to help in developing gnuplot 3.6. What can I do?
  121.  
  122.   Section 6: Making life easier
  123.  
  124.      * Q6.1: How do I plot two functions in non-overlapping regions?
  125.      * Q6.2: How do I run my data through a filter before plotting?
  126.      * Q6.3: How do I make it easier to use gnuplot with LaTeX?
  127.      * Q6.4: How do I save and restore my settings?
  128.      * Q6.5: How do I plot lines (not grids) using splot?
  129.      * Q6.6: How do I plot a function f(x,y) which is bounded by
  130.        other functions in the x-y plain?
  131.      * Q6.7: How do I get rid of <feature in a plot>?
  132.      * Q6.8: How do I call gnuplot from my own programs ?
  133.  
  134.   Section 7: Known Problems
  135.  
  136.      * Q7.1: Gnuplot is not plotting any points under X11! How come?
  137.      * Q7.2: My isoline data generated by a Fortran program is not
  138.        handled correctly. What can I do?
  139.      * Q7.3: Why does gnuplot ignore my very small numbers?
  140.      * Q7.4: Gnuplot is plotting nothing when run via gnuplot
  141.        <filename>! What can I do?
  142.      * Q7.5: My formulas are giving me nonsense results! What's going
  143.        on?
  144.      * Q7.6: My Linux gnuplot complains about a missing gnuplot_x11.
  145.        What is wrong?
  146.      * Q7.7: set output 'filename' isn't outputting everything it
  147.        should!
  148.  
  149.   Section 8: Credits
  150.  
  151.   Section 0: Meta-Questions.
  152.  
  153.    Q0.1: Where do I get this document?
  154.           This document is posted about once every two weeks to the
  155.           newsgroups comp.graphics.apps.gnuplot, comp.answers and
  156.           news.answers. Like many other FAQ's, its newest (plaintext)
  157.           version is available via anonymous ftp from
  158.           ftp://rtfm.mit.edu/pub/usenet/news.answers/graphics/gnuplot
  159.           -faq.
  160.  
  161.           If you have access to the WWW, you can get the newest version
  162.           of this document from
  163.           http://www.uni-karlsruhe.de/~ig25/gnuplot-faq/
  164.  
  165.    Q0.2: Where do I send comments about this document?
  166.           Send comments, suggestions etc. via e-mail to Thomas
  167.           Koenig, Thomas.Koenig@ciw.uni-karlsruhe.de or
  168.           ig25@dkauni2.bitnet.
  169.  
  170.  
  171.   Section 1: General Information
  172.  
  173.    Q1.1: What is gnuplot?
  174.           Gnuplot is a command-driven interactive function plotting
  175.           program. It can be used to plot functions and data points in
  176.           both two- and three- dimensional plots in many different
  177.           formats, and will accommodate many of the needs of today's
  178.           scientists for graphic data representation. Gnuplot is
  179.           copyrighted, but freely distributable; you don't have to pay
  180.           for it.
  181.  
  182.    Q1.2: How did it come about and why is it called gnuplot?
  183.           The authors of gnuplot are:
  184.  
  185.           Thomas Williams, Colin Kelley, Russell Lang, Dave Kotz, John
  186.           Campbell, Gershon Elber, Alexander Woo and many others.
  187.  
  188.           The following quote comes from Thomas Williams:
  189.  
  190.      I was taking a differential equation class and Colin was taking
  191.      Electromagnetics, we both thought it'd be helpful to visualize the
  192.      mathematics behind them. We were both working as sys admin for an
  193.      EE VLSI lab, so we had the graphics terminals and the time to do
  194.      some coding. The posting was better received than we expected, and
  195.      prompted us to add some, albeit lame, support for file data.
  196.  
  197.      Any reference to GNUplot is incorrect. The real name of the program
  198.      is "gnuplot". You see people use "Gnuplot" quite a bit because many
  199.      of us have an aversion to starting a sentence with a lower case
  200.      letter, even in the case of proper nouns and titles. Gnuplot is not
  201.      related to the GNU project or the FSF in any but the most
  202.      peripheral sense. Our software was designed completely
  203.      independently and the name "gnuplot" was actually a compromise. I
  204.      wanted to call it "llamaplot" and Colin wanted to call it "nplot."
  205.      We agreed that "newplot" was acceptable but, we then discovered
  206.      that there was an absolutely ghastly pascal program of that name
  207.      that the Computer Science Dept. occasionally used. I decided that
  208.      "gnuplot" would make a nice pun and after a fashion Colin agreed.
  209.  
  210.    Q1.3: Does gnuplot have anything to do with the FSF and the GNU
  211.           project?
  212.           Gnuplot is neither written nor maintained by the FSF. It is not
  213.           covered by the General Public License, either.
  214.  
  215.           However, the FSF has decided to distribute gnuplot as part of
  216.           the GNU system, because it is useful, redistributable software.
  217.  
  218.    Q1.4: What does gnuplot offer?
  219.  
  220.           + Plotting of two-dimensional functions and data points in many
  221.             different styles (points, lines, error bars)
  222.           + plotting of three-dimensional data points and surfaces in
  223.             many different styles (contour plot, mesh).
  224.           + support for complex arithmetic
  225.           + self - defined functions
  226.           + support for a large number of operating systems, graphics
  227.             file formats and devices
  228.           + extensive on-line help
  229.           + labels for title, axes, data points
  230.           + command line editing and history on most platforms
  231.  
  232.    Q1.5: Is gnuplot suitable for batch processing?
  233.           Yes. You can read in files from the command line, or you can
  234.           redirect your standard input to read from a file. Both data and
  235.           command files can be generated automatically, from data
  236.           acquisition programs or whatever else you use.
  237.  
  238.    Q1.6: Can I run gnuplot on my computer?
  239.           Gnuplot is available for a number of platforms. These are: Unix
  240.           (X11 and NeXTSTEP), VAX/VMS, OS/2, MS-DOS, Amiga, MS-Windows,
  241.           OS-9/68k, Atari ST and the Macintosh. Modifications for NEC
  242.           PC-9801 are said to exist (where?).
  243.  
  244.  
  245.   Section 2: Setting it up
  246.  
  247.    Q2.1: What is the current version of gnuplot?
  248.           The current version of gnuplot is 3.5, which is a bugfix
  249.           release over 3.4.
  250.  
  251.           Version 3.6 is in beta status. Please note that this is still
  252.           unstable, and may not compile correctly on your system.
  253.  
  254.    Q2.2: Where can I get gnuplot?
  255.           All of the later addresses refer to ftp sites. Please note that
  256.           it is preferable for you to use the symbolic name, rather than
  257.           the IP address given in brackets, because that address is much
  258.           more subject to change.
  259.  
  260.           The official distribution site for the gnuplot source is
  261.           ftp.dartmouth.edu [129.170.16.4, soon to be 129.170.8.11],
  262.           the file is called /pub/gnuplot/gnuplot3.5.tar.Z. Official
  263.           mirrors of that distribution are (for Australia)
  264.           ftp.monash.edu.au [130.194.11.18] and (for Europe)
  265.           irisa.irisa.fr [131.254.254.2]. You can also get it from your
  266.           friendly neighbourhood comp.sources.misc archive.
  267.  
  268.           MS-DOS and MS-Windows binaries are available from
  269.  
  270.           + oak.oakland.edu (North America) [141.210.10.117] as
  271.             /Simtel/msdos/plot/gpt35*.zip,
  272.           + garbo.uwasa.fi (Europe) [193.166.120.5] as
  273.             /pc/plot/gpt35*.zip and
  274.           + archie.au (Australia) [139.130.4.6] as
  275.             micros/pc/oak/plot/gpt35*.zip.
  276.  
  277.           The files are: gpt35doc.zip, gpt35exe.zip, gpt35src.zip and
  278.           gpt35win.zip.
  279.  
  280.           There is a special MS-DOS version for 386 or better processors;
  281.           it is available from the official gnuplot sites as DOS34.zip.
  282.  
  283.           OS/2 2.x binaries are at ftp-os2.nmsu.edu [128.123.35.151],
  284.           in /os2/2.x/unix/gnuplt35.zip.
  285.  
  286.           Amiga sources and binaries are available from ftp.wustl.edu
  287.           [128.252.135.4] as /pub/aminet/util/gnu/gnuplot-3.5.lha; there
  288.           are numerous mirrors of this distribution, for example
  289.           ftp.uni-kl.de, oes.orst.edu or ftp.luth.se.
  290.  
  291.           The NeXTSTEP front end can be found at
  292.           ftp://next-ftp.peak.org/pub/next/binaries/plotting/ as
  293.           Gnuplot1.2_bin.tar.Z.
  294.  
  295.           A version for OS-9/68K can be found at cabrales.cs.wisc.edu
  296.           [128.105.36.20] as /pub/OSK/GRAPHICS/gnuplot32x.tar.Z; it
  297.           includes both X-Windows and non - X-windows versions.
  298.  
  299.           There is a version for the Macintosh at
  300.           ftp://ftp.ee.gatech.edu/pub/mac/gnuplot/ which includes
  301.           binaries for 68000-based Macs with and without FPU and native
  302.           support for PowerMacs.
  303.  
  304.           Versions for the Atari ST and TT, which include some GEM
  305.           windowing support, are available from
  306.           ftp://ftp.uni-kl.de/pub/atari/graphics/, as gplt35st.zip
  307.           and gplt35tt.zip. They work best under MiNT.
  308.  
  309.           Executable files, plus documentation in Japanese, exist for the
  310.           X680x0 on
  311.           ftp://ftp.csis.oita-u.ac.jp/pub/x68k/fj.binaries.x68000/vol
  312.           2.
  313.  
  314.           People without ftp access can use an ftp-mail server; send a
  315.           message saying 'help' to bitftp@pucc.bitnet (for BITNET only)
  316.           or to ftpmail@ftp.dartmouth.edu.
  317.  
  318.           For a uuencoded copy of the the gnuplot sources (compressed tar
  319.           file), send this as the body of a message to
  320.           ftpmail@ftp.dartmouth.edu:
  321.  
  322.  
  323.         open
  324.         cd pub/gnuplot
  325.         mode binary
  326.         get gnuplot3.5.tar.Z
  327.         quit
  328.  
  329.    If you have some problem, you might need to stick
  330.  
  331.         reply-to  <your-email-address-here>
  332.  
  333.    before all the above.
  334.  
  335.           It is a good idea to look for a nearby ftp site when
  336.           downloading things. You can use archie for this. See if an
  337.           archie client is installed at your system (by simply typing
  338.           archie at the command prompt), or send mail to archie@sura.net
  339.           with the word 'help' in both the subject line and the body of
  340.           the mail. However, be aware that the version you find at a near
  341.           ftp site may well be out of date; check the last modification
  342.           date and the number of bytes against the newest release at one
  343.           of the official servers.
  344.  
  345.           You can obtain a beta release of gnuplot 3.6 from
  346.           ftp://cmpc1.phys.soton.ac.uk/pub/.
  347.  
  348.    Q2.3: How do I get gnuplot to compile on my system?
  349.           As you would any other installation. Read the files README and
  350.           README.Install, edit the Makefile according to taste, and run
  351.           make or whatever is suitable for your operating system.
  352.  
  353.           If you get a complaint about a missing file libplot.a or
  354.           something similar when building gnuplot for X11, remove
  355.           -DUNIXPLOT from the TERMFLAGS= line, remove -lplot from the
  356.           DTBS= line and run again. If you are making X11 on a sun, type
  357.           'make x11_sun'.
  358.  
  359.           For compiling gnuplot under Irix 5.2 and Irix 5.3, there is a
  360.           patch in the file lvs.zip in the contrib directory at
  361.           ftp.dartmouth.edu.
  362.  
  363.    Q2.4: What documentation is there, and how do I get it?
  364.           The documentation is included in the source distribution. Look
  365.           at the docs subdirectory, where you'll find
  366.  
  367.           + a Unix man page, which says how to start gnuplot
  368.           + a help file, which also can be printed as a manual
  369.           + a tutorial on using gnuplot with LaTeX
  370.           + a quick reference summary sheet for TeX only
  371.  
  372.           PostScript copies of the documentation can be ftp'd from
  373.           ftp.dartmouth.edu, in pub/gnuplot, as manual.ps.Z and
  374.           tutorial.ps.Z
  375.  
  376.           Andy Liaw and Dick Crawford have written a 16-page user's
  377.           guide. It is available from
  378.           ftp://picard.tamu.edu/pub/gnuplot/ as gptug.tex (also get
  379.           example.tex from the same directory), gptug.dvi or gptug.ps.
  380.  
  381.           At the same site, there's a two- page instruction sheet for the
  382.           enhpost PostScript driver (see Q4.6 ) as enhpost.guide.ps
  383.           and a short guide to gnuplot PostScript files, as gp-ps.doc.
  384.  
  385.           A Chinese translation of the gnuplot manual can be found on
  386.           ftp://servers.nctu.edu.tw/misc/environment/NCTU_EV/classnot
  387.           e/gnuplot.ps.gz .
  388.  
  389.           There is a WWW hompepage for gnuplot at
  390.           http://www.cs.dartmouth.edu/gnuplot_info.html, which
  391.           includes the reference manual and a demo.
  392.  
  393.           There are two more Chinese documents about gnuplot: a 72 - page
  394.           User's guide
  395.           ftp://phi.sinica.edu.tw/pub/aspac/doc/94/94002.ps.gz and a
  396.           28 - page Touring Guide
  397.           ftp://phi.sinica.edu.tw/pub/aspac/doc/95/95006.ps.gz. Both
  398.           documents are in PostScript format and gzipped.
  399.  
  400.  
  401.   Section 3: Working with it
  402.  
  403.    Q3.1: How do I get help?
  404.           Give the 'help' command at the initial prompt. After that, keep
  405.           looking through the keywords. Good starting points are 'plot'
  406.           and 'set'.
  407.  
  408.           Read the manual, if you have it.
  409.  
  410.           Look through the demo subdirectory; it should give you some
  411.           ideas.
  412.  
  413.           Ask your colleagues, the system administrator or the person who
  414.           set up gnuplot.
  415.  
  416.           Post a question to comp.graphics.apps.gnuplot or send mail
  417.           to the gatewayed mailing list info-gnuplot@dartmouth.edu. If
  418.           you want to subscribe to the mailing list, send a mail to
  419.           majordomo@dartmouth.edu with the body of the message being
  420.           'subscribe info-gnuplot'. Please don't do this if you can get
  421.           comp.graphics.apps.gnuplot directly. If you pose a
  422.           question there, it is considered good form to solicit e-mail
  423.           replies and post a summary.
  424.  
  425.    Q3.2: How do I print out my graphs?
  426.           The kind of output produced is determined by the 'set terminal'
  427.           command; for example, 'set terminal postscript' will produce
  428.           the graph in PostScript format. Output can be redirected using
  429.           the 'set output' command.
  430.  
  431.           As an example, the following prints out a graph of sin(x) on a
  432.           Unix machine running the X Window system.
  433.  
  434.  
  435.         gnuplot> plot [-6:6] sin(x)
  436.         gnuplot> set terminal postscript
  437.         Terminal type set to 'postscript'
  438.         Options are 'landscape monochrome "Courier" 14'
  439.         gnuplot> set output "sin.ps"
  440.         gnuplot> replot
  441.         gnuplot> set output              # set output back to default
  442.         gnuplot> set terminal x11        # ditto for terminal type
  443.         gnuplot> ! lp -ops sin.ps        # print PS File (site dependent)
  444.         request id is lprint-3433 (standard input)
  445.         lp: printed file sin.ps on fg20.rz.uni-karlsruhe.de (5068 Byte)
  446.         !
  447.         gnuplot>
  448.  
  449.    Q3.3: How do I include my graphs in <word processor>?
  450.           Basically, you save your plot to a file in a format your word
  451.           processor can understand (using "set term" and "set output",
  452.           see above), and then you read in the plot from your word
  453.           processor.
  454.  
  455.           Details depend on the kind of word processor you use; use "set
  456.           term" to get a list of available file formats.
  457.  
  458.           Many word processors can use Encapsulated PostScript for
  459.           graphs. This can be generated by the "set terminal postscript
  460.           eps" command. Most MS-DOS word processors understand HPGL
  461.           (terminal type hpgl).
  462.  
  463.           With TeX, it depends on what you use to print your dvi files.
  464.           If you use dvips or dvi2ps, you can use Encapsulated
  465.           PostScript. For emTeX (popular for MS-DOS), you can use emTeX,
  466.           otherwise use the LaTeX terminal type, which generates a
  467.           picture environment.
  468.  
  469.           If nothing else helps, try using the pgm or ppm format and
  470.           converting it to a bitmap format your favourite word processor
  471.           can understand. An invaluable tool for this is Jef Poskanzer's
  472.           PBMPLUS package.
  473.  
  474.           The PBMPLUS package is available in the contrib distribution
  475.           for the X Window System. The original site for this is
  476.           ftp://ftp.x.org/contrib/. There are many mirrors, e.g.
  477.           ftp://ftp.th-darmstadt.de/pub/X11/contrib/ or .
  478.           ftp://sunsite.unc.edu/pub/X11/contrib/.
  479.  
  480.           The most recent release of pbm by the author is dated December
  481.           91 and is called pbmplus10dec91.tar.Z
  482.  
  483.           There is new version including lots of patches from the net
  484.           that is not maintained by the author called netpbm, with the
  485.           newest version called netpbm-7dec1993.tar.gz.
  486.  
  487.           Check archie (see Q2.2 ) for an archive site near you.
  488.  
  489.    Q3.4: How do I post-process a gnuplot graph?
  490.           This depends on the terminal type you use.
  491.  
  492.           You can use the terminal type fig (you may need to recompile
  493.           gnuplot to enable this terminal type, by putting #define FIG
  494.           into <term.h>), and use the xfig drawing program to edit the
  495.           plot afterwards.
  496.  
  497.           For PostScript output, you may be able to use the pstotgif
  498.           script (which calls GhostScript) to convert PostScript into the
  499.           format of the tgif drawing program. Tgif is also able to save
  500.           in PostScript format.
  501.  
  502.           Both tgif and xfig can be obtained from the X Window contrib
  503.           distribution (see Q3.3).
  504.  
  505.           Another possibility for modifying PostScript output appears to
  506.           be IslandDraw, a commercial drawing program for UNIX
  507.           workstations.
  508.  
  509.           For Windows, there is another alternative, PageDraw. It can
  510.           post-process AI (Adobe Illustrator) files, and has a converter
  511.           from PostScript to AI. It can be downloaded from
  512.           http://www.wix.com/PageDraw/.
  513.  
  514.    Q3.5: How do I change symbol size, line thickness and the like?
  515.           Again, this depends on the terminal type. For PostScript, you
  516.           can edit the generated PostScript file. An overview of what
  517.           means what in the PostScript files gnuplot generates can be
  518.           found at ftp://picard.tamu.edu/pub/gnuplot/ as gs-ps.doc.
  519.           A general introduction to PostScript can be found at
  520.           ftp://unix.hensa.ac.uk/pub/misc/ukc.reports/comp.sci/repor
  521.           ts/ as 11-92.ps.Z.
  522.  
  523.    Q3.6: How do I generate plots in GIF format?
  524.           In gnuplot version 3.5, use the pbm terminal and use the
  525.           PBMPLUS package or other utilities to convert the resulting
  526.           bitmap (see Q 3.3 for how to get the PBMPLUS package).
  527.  
  528.           In 3.6, there will be a gif terminal.
  529.  
  530.  
  531.   Section 4: Wanted features
  532.  
  533.    Q4.0: What's new in gnuplot 3.6?
  534.           Here's the WhatsNew file of the current beta release,
  535.           patchlevel 213.
  536.  
  537.  
  538. What's new in 3.6 ?
  539.  
  540. Still to do
  541.   Many terminals to be converted to new layout
  542.   someone has contributed a new hidden-line-removal
  543.   '-' as load filename / command-line param
  544.   key for splot with contour is ugly
  545.   timeseries stuff has got broken (well, non-portable code)
  546.   terminals are no longer allowed to do their own scaling
  547.  
  548. Plus quite a few contributed patches that I haven't yet installed (sorry)
  549.  
  550. in 194
  551.   multiplot for splot
  552.  
  553. in 188
  554.   os9 port
  555.   set xrange [] reverse writeback
  556.   allow mix of co-ordinate systems within an arrow/label posn
  557.   initial multiplot support
  558.   - doesn't yet check that terminal is capable, but there is a
  559.     flags field added to the terminal entry to tell gnuplot about this.
  560.     also, suspend() / resume() entry points which are to be called
  561.     between plots of a multiplot.
  562.  
  563. in 178
  564.    arbitrary length/number of columns in datafile
  565.    accept double/quad-precision fortran numbers (1.23{dDqQ}4)
  566.    - but not in scanf format string
  567.    undefined fit parameters start at 1 rather than 1e-30
  568.    - more chance of convergence / less change of unitary matrix
  569.    WIN32 / Win-NT support
  570.    table output can be read back in for data splot
  571.    - hence gnuplot can be used to dgrid a datafile and write it out
  572.    set missing 'string'
  573.    - nominate a token as standing for missing values in datafile
  574.    - not yet added to documentation
  575.    updates to time-series stuff (so it doesn't break at 2000)
  576.    - except it has become horribly non-portable :-(
  577.    split graph3d.c into util3d.c and hidden3d.c
  578.  
  579. in 166
  580.    set bar <size>
  581.    - a number rather than just small or large
  582.    allow different linetypes for grid at major and minor tics
  583.    a few more set no* commands for consistency.
  584.    initial go at implementing tic mirrors and axes for splot
  585.    - no ztic axis yet (or no zzeroaxis)
  586.    - tics on axes are not hidden by surface
  587.    attempt to make sin(x) behave as expected when set angle degrees
  588.    - gives answers if x is complex, but I dont know if they are correct
  589.      - acos(cos(x)) seems to give x, so at least its consistent
  590.    - fix a bug which made acos(cos({0,1})) undefined
  591.    new grass.trm
  592.  
  593. in release 162/164
  594.    set size [{no}square] x,y  - tries to plot with aspect ratio 1
  595.    - seems to work great for postscript
  596.    - please check with your favourite driver
  597.    - uses relative sizes of tics to determine required size.
  598.    posn for key, labels and arrows can be in one of 4 co-ordinate systems
  599.    - first_axes (default)
  600.    - second_axes (for plot..second)
  601.    - graph  (0,0 -> 1,1 = plotting area)
  602.    - screen (0,0 -> 1,1 = whole screen)
  603.    - arrows needn't have endpoints in same co-ords. see help set label
  604.    via is now a required keyword for fit
  605.    - fit f(x) 'file' ... via { 'file' | a,b,... }
  606.    - this is to avoid confusing 'file' with 'using-format-string'
  607.    win32 and 16-bit dos fixes
  608.    - I can compile with tc++, but get an overlay error at runtime.
  609.    new set of documentation programs (I haven't tried them)
  610.    various tweaks to makefile
  611.    changes to pslatex
  612.    - substitute .ps at _last_ . in filename
  613.    - accept font size of enclosing document as an option.
  614.    - dont forget to close aux file
  615.  
  616. in release 151
  617.  
  618.   linux security patch
  619.   can specify font for labels, etc (postscript only ? - I haven't tried this)
  620.   can specify linetype to draw grid / zeroaxes / arrows
  621.   emx terminal driver
  622.   first attempt at pipes for VMS and vector style - needs more work
  623.   l/b/r/t-margin  in place of xmargin - more control over size of margins
  624.   incompatible changes to polar mode:
  625.   - t is now the dummy variable, so x is width of plot as expected
  626.   - tics are not automatically on axes -   set {xy}tics axis nomirror
  627.   - grid is not automatically polar - set grid x [mx] polar [angle]
  628.   - no numbers on grid - they were always in degrees
  629.   second axes
  630.   - x2 and y2 are an independent pair of axes, but they inherit
  631.     ranges from x and y if no second data
  632.     - there can be problems with this, actually - if x2tics are not
  633.       shown, x2range is not autoextended to whole number of tics, so
  634.       same data might not have same range.
  635.   - set x2tics/y2tics/x2label/y2label
  636.   - set [no]log x2 / y2
  637.   - plot [first,] f(x), 'file', ..., second, g(x), ...
  638.   - get specify grid at any/all of x,y,x2,y2
  639.   - see electron.dem
  640.   set border <mask> - 12 bit binary number selects 12 sides of cube around splo
  641. t
  642.   can specify grid z, to get a grid on back wall of splot
  643.   set mxtics [<interval>|default] | set nomxtics
  644.   - set mxtics  gives auto for logscale, fixed for linear
  645.   binary, index and every keywords to datafiles.
  646.   - every also works with binary files
  647.   can use '-' as datafile for inline data (ends at line with e)
  648.   can use '' to mean reuse previous file
  649.   splot and fit now use datafile module
  650.   - FIT_SKIP no longer supported - use fit f(x) 'file' every n
  651.   can limit fit range using   fit [variable=min:max] f(variable) ...
  652.   set ticscale <major> [<minor>]
  653.   surface is clipped with no hidden line removal
  654.   - still to do contour and hidden-line surface
  655.   set {x|y|x2|y2} [axis|border] [no]mirror
  656.   - can put tics on border or axes
  657.   - mirror controls mirroring of tics on opposite axis
  658.     - no longer coupled to  set tics out  setiing.
  659.   No longer need to specify parametric mode for 3-column data files.
  660.   ranges automatically extended to whole number of tic intervals
  661.   - doesn't always manage to drop vertical from surface to corner of base
  662.     - workaround is either specify range or use  set border
  663.  
  664. patchlevel 140
  665. --------------
  666. I've probably missed a lot of features since I'm so used to them.
  667. Plus I never bothered with 3.5 so some of these may have been there.
  668. some of these may have made it into the documentation
  669. Here goes:
  670.  
  671.   fit f(x) 'file' via ...
  672.   read and plot time data  (timedat.dem)
  673.   set key [top|bottom|under] [left|right|out] [reverse] [box [<linetype>]]
  674.   set key title 'text'
  675.   Processing of escape sequences in "strings" but not 'strings'
  676.   - TeX users in particular advised to use ''
  677.   Multiline labels, etc, using "first\nsecond"
  678.   enhpost driver
  679.   call command (load with parameters)
  680.   x error bars. splines. boxes. [some may have been in 3.5]
  681.   pipes for amiga
  682.   the using patch   plot 'file' using spec:spec:...
  683.   - spec is either column number or (expression in $1, $2, ...)
  684.   new pslatex driver with postscript to aux file.
  685.   set pointsize <scale factor> on some terminals
  686.   doubles in  plot...using  format string - %lf
  687.   unlimited input line length and expression (action) table
  688.   minor tic-marks (like logscale but also for linear)
  689.   - also set grid [mx|my]
  690.  
  691.  
  692.  
  693. that's all I can think of for the moment...
  694.  
  695.    Q4.1: Does gnuplot have hidden line removal?
  696.           Version 3.5 supports hidden line removal on all platforms
  697.           except MS-DOS; use the command
  698.  
  699.  
  700.         set hidden3d
  701.  
  702.    If someone can solve the 64K DGROUP memory problem, gnuplot would
  703.           support hidden line removal on MS-DOS as well. Version 3.2
  704.           supports limited hidden line removal.
  705.  
  706.    Q4.2: Does gnuplot support bar-charts/histograms/boxes?
  707.           As of version 3.4, it does; use the style "with boxes" for bar
  708.           charts. To get filled boxes, you can try a modification by
  709.           Steve Cumming, available via ftp from
  710.           ftp://grebe.geog.ubc.ca/pub/gnuplot as box.tar.
  711.  
  712.    Q4.3: Does gnuplot support multiple y-axes on a single plot?
  713.           Yes, with two unofficial mods, multiplot.shar and borders.shar.
  714.           They can be obtained from
  715.           ftp://ftp.dartmouth.edu/pub/gnuplot/contrib/multi_woo.zip
  716.           or ftp://ftp.cygnus.edu/incoming/gpx38.zip.
  717.  
  718.           Also, 3.6 supports this capability.
  719.  
  720.    Q4.4: Can I put multiple plots on a single page?
  721.           Yes, with the multiplot.shar mod, or if you are running gnuplot
  722.           3.6. If you are using PostScript output, check out mpage, which
  723.           can be ftp'd from ftp.eng.umd.edu:pub/misc/mpage-2.tar.Z
  724.  
  725.    Q4.5: Can I put both data files and commands into a single file?
  726.           This feature is in gnuplot 3.6.
  727.  
  728.    Q4.6: Can I put Greek letters and super/subscripts into my labels?
  729.           You might try using the LaTeX terminal type and putting text
  730.           like \alpha_{3} into it.
  731.  
  732.           David Denholm has written a PostScript terminal which allows
  733.           for super/and subscripts, such as a^x or {/Symbol a }. Ftp to
  734.           sotona.phys.soton.ac.uk [152.78.192.42] and get enhpost.trm,
  735.           written by David Denholm and Matt Heffron. To install it,
  736.           follow the instructions at the top of the file, then recompile.
  737.           enhpost is also included in gnuplot 3.6.
  738.  
  739.    Q4.7: Can I do 1:1 scaling of axes?
  740.           Not easily in 3.5; in 3.6, you can use "set size square".
  741.  
  742.    Q4.8: Can I put tic marks for x and y axes into 3d plots?
  743.           In version 3.5, you can; use the "with boxes" option.
  744.  
  745.    Q4.9: Does gnuplot support a driver for <graphics format>?
  746.           To see a list of the available graphic drivers for your
  747.           installation of gnuplot, type "set term".
  748.  
  749.           Some graphics drivers are included in the normal distribution,
  750.           but are uncommented by default. If you want to use them, you'll
  751.           have to change ~gnuplot/term.h, and recompile.
  752.  
  753.    Q4.10: Can I put different text sizes into my plots?
  754.           If you use PostScript output, you can use Dave Denholm's and
  755.           Matt Heffron's updated PostScript driver,
  756.           /sotona.phys.soton.ac.uk:/enhpost.trm (see also Q4.6 ).
  757.           Else, use 3.6.
  758.  
  759.    Q4.11 How do I modify gnuplot, and apply 'patches'?
  760.           For this, you will need to recompile gnuplot.
  761.  
  762.           Modifications people make are either done by replacing files,
  763.           such as terminal drivers, or by 'patching'. If a file is a
  764.           replacement, it will probably tell you in its README or in the
  765.           lines at the beginning.
  766.  
  767.           To patch a file, you need Larry Wall's patch utility. On many
  768.           UNIX systems, it is already installed; do a man patch to check.
  769.           If it isn't, you'll have to get it; it can be found wherever
  770.           GNU software is archived.
  771.  
  772.    Q4.12 How do I skip data points?
  773.           By specifying ? as a data value, as in
  774.  
  775.  
  776.         1 2
  777.         2 3
  778.         3 ?
  779.         4 5
  780.  
  781.    Q4.13 How do I plot every nth point?
  782.           You can apply the patch point_skip from the contrib section
  783.           (see Q5.3 or, assuming you have awk installed on your
  784.           system, you can use the following line:
  785.  
  786.  
  787.         gnuplot> plot "< awk '{if(NR%5==0)print}' file.dat"
  788.  
  789.    plots every 5th line, and
  790.  
  791.         gnuplot> plot "< awk '$0 !~ /^#/ {if(NR%40==0)print $1, $4}' file.dat"
  792.  
  793.    plots every 40th line while skipping commented lines.
  794.  
  795.  
  796.   Section 5: Miscellaneous
  797.  
  798.    Q5.1: I've found a bug, what do I do?
  799.           First, try to see whether it actually is a bug, or whether it
  800.           is a feature which may be turned off by some obscure set -
  801.           command.
  802.  
  803.           Next, see wether you have an old version of gnuplot; if you do,
  804.           chances are the bug has been fixed in a newer release.
  805.  
  806.           If, after checking these things, you still are convinced that
  807.           there is a bug, proceed as follows. If you have a fairly
  808.           general sort of bug report, posting to
  809.           comp.graphics.apps.gnuplot is probably the way to go. If
  810.           you have investigated a problem in detail, especially if you
  811.           have a context diff that fixes the problem, please e-email a
  812.           report to bug-gnuplot@dartmouth.edu. The bug-gnuplot list is
  813.           for reporting and collecting bug fixes, the
  814.           comp.graphics.apps.gnuplot newsgroup will be more help for
  815.           finding work arounds or actually solving gnuplot related
  816.           problems. If you do send in a bug report, be sure and include
  817.           the version of gnuplot (including patchlevel), terminal driver,
  818.           operating system, an exact description of the bug and input
  819.           which can reproduce the bug. Also, any context diffs should be
  820.           referenced against the latest official version of gnuplot if at
  821.           all possible.
  822.  
  823.    Q5.2: Can I use gnuplot routines for my own programs?
  824.           Yes. John Campbell <jdc@nauvax.ucc.nau.edu> has written
  825.           gplotlib, a version of gnuplot as C subroutines callable from a
  826.           C program. This is available as gplotlib.tar.Z on the machine
  827.           ftp.nau.edu in the directory /pub/gplotlib.tar.Z. This library
  828.           has been updated to be compatible with version 3.5.
  829.  
  830.    Q5.3: What extensions have people made to gnuplot? Where can I get
  831.           them?
  832.           __Extensions are available from
  833.           ftp://ftp.dartmouth.edu/pub/gnuplot/contrib/ . It contains
  834.           the following files:
  835.  
  836.     Point Skips
  837.  
  838.           + _Data Filtering_ Instead of just having two params
  839.             following the style param, there are now 4:
  840.                o 1: line_type
  841.                o 2: point_type
  842.                o 3: point_skip - gives the number of data samples per
  843.                  plotted point
  844.                o 4: point_offs - gives the sample number on which to plot
  845.                  the first point
  846.             Thus points are plotted only for the samples n satisfying n =
  847.             point_skip*i + point_offs for some non-negative integer i.
  848.             From:
  849.             pixar!sun!prony.Colorado.EDU!clarkmp@ucbvax.berkeley.edu
  850.             (Michael Clark)
  851.           + _Point Skip with Awk_ With UNIX,
  852.  
  853. gnuplot> plot "< awk '{if(NR%5==0)print$0}' file.dat"
  854.         From: James Darrell McCauley, mccauley@ecn.purdue.edu
  855.           + _New Xlib mods._ From: gregg hanna
  856.             (gregor@kafka.saic.com)
  857.  
  858.     Vectors and Arrows
  859.           + _Program to convert lines to vectors_ This program turns
  860.             line segments into line segments with a half-arrow at the
  861.             head: by uncommenting two lines below, the arrowhead will be
  862.             a triangle. optional arguments: size angle where size is a
  863.             fraction of each vector's magnitude and angle is in degrees
  864.             all data taken from standard input, and output to standard
  865.             output. typical invocation:
  866.  
  867. arrow 0.2 15 <vector.lin >vector.heads
  868.         From: andrew@jarthur.claremont.edu (Andrew M. Ross)
  869.           + _Vect2gp_, an awk script to make gnuplot command script
  870.             to draw a vector field map. From: hiro@ice3.ori.u-tokyo.ac.jp
  871.             (Yasu-Hiro YAMAZAKI)
  872.           + _GNUPLOT to SIPP_ This is a "far from perfect" converter
  873.             that takes gnuplot table output and splits it in polygons.
  874.             Then it calls sipp to render it. You get sipp from
  875.             isy.liu.se:/pub/sipp or ask archie. From:
  876.             chammer@POST.uni-bielefeld.de (Carsten Hammer)
  877.  
  878.     Histograms and Pie Charts
  879.           + _Histogram C program_ The short C program below is a
  880.             filter that calculates a histogram from a sequence of numbers
  881.             and prints the output in such a format that Gnuplot can plot
  882.             the histogram by the command sequence
  883.  
  884.     !histogram < datain > tmp;
  885.     plot "tmp" with impulses
  886.             From: mustafa@seas.smu.edu (Mustafa Kocaturk)
  887.           + _HG_ is an automatic histogram generator. it reads a
  888.             column of data from an input file and emits a [log] histogram
  889.             ks does ks or chi^2 tests on a set of input arrays. you need
  890.             the "numerical recipes in C" library somewhere on your system
  891.             to link this one. I can not undertake to fix bugs or add
  892.             features, but I might do it if asked. From: Steve Cumming
  893.             stevec@geog.ubc.ca
  894.           + _Piechart C program_ The short C program below formats
  895.             data for display as a piechart. From: mccauley@ecn.purdue.edu
  896.             (James Darrell McCauley)
  897.  
  898.     Interprocess Communications
  899.           + _Notes of Windows Hooks_ From: Maurice
  900.             Castro,maurice@bruce.cs.monash.edu.au
  901.           + _Named Pipes Example _From:
  902.             dtaber@deathstar.risc.rockwell.com (Don Taber)
  903.           + _PipeLib_ What the library does is set up to 20 programs
  904.             going (like gnuplot), then allows you to send to them as if
  905.             the program were typing on the command line. I've included a
  906.             brief set of docs after the source code, in latex format.
  907.             There is no facility to watch the output of a program. From:
  908.             ssclift@neumann.uwaterloo.ca (Simon Clift)
  909.           + _Popen example from lsqrfit_ The following function
  910.             sends a command to gnuplot. Gnuplot will execute the command
  911.             just as if you typed it at the gnuplot command line. This
  912.             example is adapted from my least squares fitting program
  913.             which is located at ftp.cdrom.com in
  914.             pub/os2/2_x/unix/lsqrft14.zip. Complete source is included.
  915.             From: michael@krypton.mit.edu (Michael Courtney)
  916.  
  917.     Multiple logical plots on a single page
  918.           + _Gawk script for multiple encapsulated postscript on a
  919.             page_ It's slightly more flexible than mpage, because it
  920.             changes the aspect ratio of the plots; mpage according to the
  921.             documentation only allows 1, 2, 4, or 8 plots on a page. This
  922.             script works for unix with encapsulated postscript (eps)
  923.             output. It should work with gawk or nawk, although I've only
  924.             tested it with gawk. (Gawk is GNU's version of awk and is
  925.             available from prep.ai.mit.edu.) You just specify how many
  926.             rows and columns of plots you want and it does the rest. For
  927.             example, gnuplot_eps rows=3 cols=2 *.eps | lpr will print all
  928.             eps files in your current directory with 6 on a page. Also,
  929.             see the comments in the file. From:
  930.             holt@goethe.cns.caltech.edu (Gary Holt)
  931.           + _Sed script for multiple encapsulated postscript on a
  932.             page_ You have MULTIPLE postscript files each containing a
  933.             single plot. From: wgchoe@scoupe.postech.ac.kr (Choe Won Gyu)
  934.           + _Massive patch_ with add multiplotcapability to all
  935.             devices and a lot more. The reason it is offered in this form
  936.             is because the original multiplot.pat did not patch correctly
  937.             into gnuplot version 3.5. This mod also add borders options,
  938.             financial plots, multiple line titles and other asundry
  939.             items. Use at your own risk. Look at the top of makefile.r
  940.             for a more complete list of changes.
  941.             From: Alex Woo, woo@playfair.stanford.edu
  942.  
  943.     lvs.zip
  944.             This contains miscellaneous, modifications, which include:
  945.           + Label positioning using either plot or device-relative
  946.             coodinates
  947.           + Portability to Irix-5.2 and Irix-5.3
  948.           + The "thru" keyword has been extended to include "thrux" for
  949.             the X - Coordinate
  950.           + Capability to read a ordinary Fortran-style unformatted file
  951.           + A Perl script for better handling of eps
  952.           + Modifications to docs/doc2info to generate "next", "prev",
  953.             and "up" data for each node.
  954.           + Changes in the documentation to reflect the above.
  955.  
  956.     Miscellaneous Mods
  957.           + _Congp3d3_ is a preprocessor to draw contour plots on
  958.             irregular regions. From: mrb2@nrc.gov (Margaret Rose Byrne)
  959.           + _Sockpipe_ is a socket based pipe needed for the
  960.             Stardent OS. From: Mike Hallesy, Stardent Computer Product
  961.             Support, hal@stardent.com
  962.           + _Time Series_ is a patch to add multiline titles and
  963.             labels, time series x and y data and tic marks, and automatic
  964.             resizing of plots and much more. From: Hans Olav Eggestad,
  965.             olav@jordforsk.nlh.no
  966.  
  967.     Other Operationing Systems
  968.           + _MacIntosh Port of Version 3.2_ From: Noboru Yamamoto,
  969.             sun!kekvax.kek.jp!YAMAMOTO@pixar.com
  970.           + _MacIntosh Port of Version 3.5_ From:
  971.             laval@londres.cma.fr (Philippe LAVAL)
  972.           + _OS-9 Port of Version 3.2_
  973.  
  974.  
  975.    Q5.4: Can I do heavy - duty data processing with gnuplot?
  976.           Gnuplot alone is not suited very well for this. One thing you
  977.           might try is fudgit, an interactive multi-purpose fitting
  978.           program written by Martin-D. Lacasse
  979.           (isaac@frodo.physics.mcgill.ca). It can use gnuplot as its
  980.           graphics back end and is available from ftp.physics.mcgill.ca
  981.           in /pub/Fudgit/fudgit_2.33.tar.Z [132.206.9.13], and from the
  982.           main Linux server, tsx-11.mit.edu [18.172.1.2] and its numerous
  983.           mirrors around the world as
  984.           /pub/linux/sources/usr.bin/fudgit-2.33.tar.z. Versions are
  985.           available for AIX, Data General, HP-UX, IRIX 4, Linux, NeXT,
  986.           Sun3, Sun4, Ultrix, OS/2 and MS-DOS. The MS-DOS version is
  987.           available on simtel20 mirrors (simtel20 itself has closed down)
  988.           in the "math" subdirectory as fudg_231.zip.
  989.  
  990.           Carsten Grammes has written a fitting program which goes
  991.           together with gnuplot; it is called gnufit and is available
  992.           from the official gnuplot sites, as the files gnufit12.info,
  993.           gnufit12.tar.gz (source) and gft12dos.zip (MS-DOS). It has been
  994.           merged into gnuplot 3.6.
  995.  
  996.           Michael Courtney has written a program called lsqrft, which
  997.           uses the Levenberg - Marquardt - Algorithm for fitting data to
  998.           a function. It is avialiable from ftp.cdrom.com as
  999.           /pub/os2/2_x/unix/lsqrft13.zip; sources, which should compile
  1000.           on Unix, and executables for MS-DOS and OS/2 2.x are included.
  1001.           There is an interface to the OS/2 presentation manager.
  1002.  
  1003.           You might also want to look at the applications developed by
  1004.           the Software Tools Group (STG) at the National Center for
  1005.           Supercomputing Applications. Ftp to ftp.ncsa.uiuc.edu
  1006.           [141.142.20.50] and get the file README.BROCHURE for more
  1007.           information.
  1008.  
  1009.           You can also try pgperl, an integration of the PGPLOT plotting
  1010.           package with Perl 5. Information can be found at
  1011.           http://www.ast.cam.ac.uk/~kgb/pgperl.html, the source is
  1012.           available from ftp://ftp.ast.cam.ac.uk/pub/kgb/pgperl/ or
  1013.           ftp://linux.nrao.edu/pub/packages/pgperl/.
  1014.  
  1015.           Another possibility is Octave. To quote from its README: Octave
  1016.           is a high-level language, primarily intended for numerical
  1017.           computations. It provides a convenient command line interface
  1018.           for solving linear and nonlinear problems numerically.
  1019.  
  1020.           The latest released version of Octave is always available via
  1021.           anonymous ftp from bevo.che.wisc.edu in the directory
  1022.           /pub/octave.
  1023.  
  1024.    Q5.5: I have ported gnuplot to another system, or patched it. What do
  1025.           I do?
  1026.           If your patch is small, mail it to bug-gnuplot@dartmouth.edu,
  1027.           with a thorough description of what the patch is supposed to
  1028.           do, which version of gnuplot it is relative to, etc. Also, you
  1029.           can send notification of the patch to the FAQ maintainer, if
  1030.           you want a mention. Please don't send the patch itself to me
  1031.           :-)
  1032.  
  1033.           If your modifications are extensive (such as a port to another
  1034.           system), upload your modifications to
  1035.           ftp://ftp.dartmouth.edu/pub/dropoff. Please drop a note to
  1036.           David.Kotz@dartmouth.edu, the maintainer of the gnuplot
  1037.           subdirectory there, plus a note to bug-gnuplot@dartmouth.edu.
  1038.  
  1039.    Q5.6: I want to help in developing gnuplot 3.6. What can I do?
  1040.           Join the gnuplot beta test mailing list by sending a mail
  1041.           containing the line
  1042.  
  1043.  
  1044. subscribe info-gnuplot-beta
  1045.  
  1046.    in the body (not the subject) of the mail to Majordomo@Dartmouth.EDU.
  1047.  
  1048.  
  1049.   Section 6: Making life easier
  1050.  
  1051.    Q6.1: How do I plot two functions in non - overlapping regions?
  1052.           Use a parametric plot. An example:
  1053.  
  1054.  
  1055.         set parametric
  1056.         a=1
  1057.         b=3
  1058.         c=2
  1059.         d=4
  1060.         x1(t) = a+(b-a)*t
  1061.         x2(t) = c+(d-c)*t
  1062.         f1(x) = sin(x)
  1063.         f2(x) = x**2/8
  1064.         plot [t=0:1] x1(t),f1(x1(t)) title "f1", x2(t), f2(x2(t)) title "f2"
  1065.  
  1066.    Q6.2: How do I run my data through a filter before plotting?
  1067.           If your system supports the popen() function, as Unix does, you
  1068.           should be able to run the output through another process, for
  1069.           example a short awk program, such as
  1070.  
  1071.  
  1072.         gnuplot> plot "< awk ' { print $1, $3/$2 } ' file.in"
  1073.  
  1074.    Unfortunately, in 3.2, there is a rather short limitation on the
  1075.           maximum argument length, so your command line may be truncated
  1076.           (usually, this will mean that awk cannot find the filename).
  1077.           Also, you may need to escape the $ - characters in your awk
  1078.           programs.
  1079.  
  1080.           As of version 3.4, gnuplot includes the thru - keyword for the
  1081.           plot command for running data files through a gnuplot - defined
  1082.           function.
  1083.  
  1084.           You can also get divhack.patch from
  1085.           sotona.phys.soton.ac.uk[152.78.192.42] via anonymous ftp. It
  1086.           allows expressions of the kind
  1087.  
  1088.  
  1089.         gnuplot> plot "datafile" using A:B:C
  1090.  
  1091.    where A,B,C,... are now either a column number, as usual, or an
  1092.           arbitrary expression enclosed in ()'s, and using $1,$2,etc to
  1093.           access the data columns.
  1094.  
  1095.    Q6.3: How do I make it easier to use gnuplot with LaTeX?
  1096.           There is a set of LaTeX macros and shell scripts that are meant
  1097.           to make your life easier when using gnuplot with LaTeX. This
  1098.           package can be found on ftp.dartmouth.edu [129.170.16.54, soon
  1099.           to be 129.170.8.11] in pub/gnuplot/latex.shar, by David Kotz.
  1100.           For example, the program "plotskel" can turn a gnuplot-output
  1101.           file plot.tex into a skeleton file skel.tex, that has the same
  1102.           size as the original plot but contains no graph. With the right
  1103.           macros, the skeleton can be used for preliminary LaTeX passes,
  1104.           reserving the full graph for later passes, saving tremendous
  1105.           amounts of time.
  1106.  
  1107.    Q6.4: How do I save and restore my settings?
  1108.           Use the "save" and "load" commands for this; see "help save"
  1109.           and "help load" for details.
  1110.  
  1111.    Q6.5: How do I plot lines (not grids) using splot?
  1112.           If the data in a data file for splot is arranged in such a way
  1113.           that each one has the same number of data points (using blank
  1114.           lines as delimiters, as usual), splot will plot the data with a
  1115.           grid. If you want to plot just lines, use a different number of
  1116.           data entries (you can do this by doubling the last data point,
  1117.           for example). Don't forget to set parametric mode, of course.
  1118.  
  1119.    Q6.6: How do I plot a function f(x,y) which is bounded by other
  1120.           functions in the x-y plain?
  1121.           An example:
  1122.  
  1123.  
  1124.         f(x,y) = x**2 + y **2
  1125.         x(u) = 3*u
  1126.         yu(x) = x**2
  1127.         yl(x) = -x**2
  1128.         set parametric
  1129.         set cont
  1130.         splot [0:1] [0:1] u,yl(x(u))+(yu(x(u)) - yl(x(u)))*v,\
  1131.         f(x(u), (yu(x(u)) - yl(x(u)))*v)
  1132.  
  1133.    Q6.7: How do I get rid of <feature in a plot>?
  1134.           Usually, there is a set command to do this; do a
  1135.  
  1136.  
  1137.         gnuplot> ?set no
  1138.  
  1139.    for a short overview.
  1140.  
  1141.    Q6.8: How do I call gnuplot from my own programs?
  1142.           Here's code which works for a UNIX system, using (efficient)
  1143.           named pipes.
  1144.  
  1145.  
  1146. #include <sys/types.h>
  1147. #include <sys/stat.h>
  1148. #include <stdlib.h>
  1149. #include <stdio.h>
  1150. #include <math.h>
  1151. #include <unistd.h>
  1152.  
  1153. #define PANIC(a) do { \
  1154.                 perror(a); \
  1155.                 if (temp_name) unlink(temp_name);\
  1156.                 exit(1);\
  1157.         } while(0)
  1158.  
  1159. int main() {
  1160.     FILE *command,*data;
  1161.     char *temp_name = NULL;
  1162.     double a,b;
  1163.     int i;
  1164.  
  1165.     if ((temp_name = tmpnam((char *) 0)) == 0) PANIC("tmpnam failed");
  1166.     if(mkfifo(temp_name, S_IRUSR | S_IWUSR) != 0) PANIC("mkfifo failed");
  1167.     command = popen("gnuplot","w");
  1168.     fprintf(command,"plot \"%s\" with lines\n",temp_name); fflush(command);
  1169.     data = fopen(temp_name,"w");
  1170.     for (i=0; i<20; i++) {
  1171.         a = i/10.0;
  1172.         b = sin(a);
  1173.         fprintf(data,"%f %f\n",a,b);
  1174.     }
  1175.     fclose(data);
  1176.     fprintf(stderr,"press enter to continue..."); fflush(stderr);
  1177.     getchar();
  1178.  
  1179.     fprintf(command,"plot \"%s\" with lines\n",temp_name); fflush(command);
  1180.     data = fopen(temp_name,"w");
  1181.     for (i=0; i<20; i++) {
  1182.         a = i/10.0;
  1183.         b = cos(a);
  1184.         fprintf(data,"%f %f\n",a,b);
  1185.     }
  1186.     fclose(data);
  1187.     fprintf(stderr,"press enter to continue..."); fflush(stderr);
  1188.     getchar();
  1189.     pclose(command);
  1190.     unlink(temp_name);
  1191.     return 0;
  1192. }
  1193.  
  1194.    Here's code for OS/2, again using named pipes; I'm unable to check
  1195.           this out myself. This code is care of fearick@physci.uct.ac.za
  1196.           (Roger Fearick).
  1197.  
  1198.  
  1199. #include <stdio.h>
  1200. #define INCL_DOS
  1201. #define INCL_DOSPROCESS
  1202. #define INCL_DOSNMPIPES
  1203. #include <os2.h>
  1204.  
  1205. main()
  1206.     {
  1207.     HPIPE hpipe ;
  1208.     FILE *hfile, *hgnu ;
  1209.         /* create a named pipe. Use NP_WAIT so that DosConnect...
  1210.            blocks until client (gnuplot) opens, and client reads
  1211.            are blocked until data is available */
  1212.     DosCreateNPipe( "\\pipe\\gtemp",
  1213.                     &hpipe,
  1214.                     NP_ACCESS_OUTBOUND,
  1215.                     NP_WAIT|NP_TYPE_BYTE|1,
  1216.                     256,
  1217.                     256,
  1218.                     -1 ) ;
  1219.         /* use stream i/o */
  1220.     hfile = fdopen( hpipe, "w" ) ;
  1221.  
  1222.         /* start gnuplot; use unbuffered writes so we don't need to
  1223.            flush buffer after a command */
  1224.     hgnu = popen( "gnuplot", "w" ) ;
  1225.     setvbuf( hgnu, NULL, _IONBF, 0 ) ;
  1226.  
  1227.         /* plot a set of data */
  1228.  
  1229.     fprintf( hgnu, "plot '/pipe/gtemp'\n" ) ;  /* issue plot command */
  1230.     DosConnectNPipe( hpipe ) ;              /* wait until 'file' opened */
  1231.     fprintf( hfile, "1 1\n" ) ;             /* write data to 'file' */
  1232.     fprintf( hfile, "2 2\n" ) ;
  1233.     fprintf( hfile, "3 3\n" ) ;
  1234.     fprintf( hfile, "4 4\n" ) ;
  1235.     fflush( hfile ) ;                       /* flush buffer forces read */
  1236.     DosSleep( 500 ) ;                       /* allow gnuplot to catch up */
  1237.     DosDisConnectNPipe( hpipe ) ;           /* disconnect this session */
  1238.     fprintf( hgnu, "pause -1\n" ) ;         /* admire plot */
  1239.  
  1240.         /* plot another set of data */
  1241.  
  1242.     fprintf( hgnu, "plot '/pipe/gtemp'\n" ) ;
  1243.     DosConnectNPipe( hpipe ) ;
  1244.     fprintf( hfile, "1 4\n" ) ;
  1245.     fprintf( hfile, "2 3\n" ) ;
  1246.     fprintf( hfile, "3 2\n" ) ;
  1247.     fprintf( hfile, "4 1\n" ) ;
  1248.     fflush( hfile ) ;
  1249.     DosSleep( 500 ) ;
  1250.     DosDisConnectNPipe( hpipe ) ;
  1251.     fprintf( hgnu, "pause -1\n" ) ;
  1252.  
  1253.     DosClose( hpipe ) ;
  1254.     pclose( hgnu ) ;
  1255.     }
  1256.  
  1257.    ; The above code works for gnuplot 3.5. In gnuplot 3.6, this can be
  1258.           greatly simplified, since data can be fed 'inline, as in
  1259.  
  1260.  
  1261. plot '-' w l
  1262. 1 1
  1263. 2 3
  1264. 3 4
  1265. e
  1266.  
  1267.  
  1268.   Section 7: Known problems
  1269.  
  1270.    Q7.1: Gnuplot is not plotting any points under X11! How come?
  1271.           Very probably, you still are using an old version of
  1272.           gnuplot_x11. Remove that, then do a full installation.
  1273.  
  1274.           On VMS, you need to make several symbols:
  1275.  
  1276.         $ gnuplot_x11 :== $disk:[directory]gnuplot_x11
  1277.         $ gnuplot :== $disk:[directory]gnuplot.exe
  1278.         $ def/job GNUPLOT$HELP disk:[directory]gnuplot.hlb
  1279.  
  1280.    Then run gnuplot from your command line, and use
  1281.  
  1282.         gnuplot> set term x11
  1283.  
  1284.    Q7.2: My isoline data generated by a Fortran program is not handled
  1285.           correctly. What can I do?
  1286.           One known cause for this is the use of list-directed output (as
  1287.           in WRITE(10,*) for generating blank lines. Fortran uses ASA
  1288.           carriage control characters, and for list - directed output
  1289.           this results in a space being output before the newline.
  1290.           Gnuplot does not like this. The solution is to generate blank
  1291.           lines using formatted output, as in WRITE(10,'()'). If you use
  1292.           carriage return files in VMS Fortran, you may have to open the
  1293.           file with OPEN(...,CARRIAGECONTROL='DTST') or convert it using
  1294.           the DECUS utility ATTRIB.EXE:
  1295.  
  1296.  
  1297.         VMS> ATTRIB/RATTRIB=IMPDTED FOR010.DAT
  1298.  
  1299.    Q7.3: Why does gnuplot ignore my very small numbers?
  1300.           Gnuplot treats all numbers less than 1e-08 as zero, by default.
  1301.           Thus, if you are trying to plot a collection of very small
  1302.           numbers, they may be plotted as zero. Worse, if you're plotting
  1303.           on a log scale, they will be off scale. Or, if the whole set of
  1304.           numbers is "zero", your range may be considered empty:
  1305.  
  1306.  
  1307.         gnuplot> plot 'test1'
  1308.         Warning: empty y range [4.047e-19:3e-11], adjusting to [-1:1]
  1309.         gnuplot> set yrange [4e-19:3e-11]
  1310.         gnuplot> plot 'test1'
  1311.                      ^
  1312.          y range is less than `zero`
  1313.  
  1314.    The solution is to change gnuplot's idea of "zero":
  1315.  
  1316.         gnuplot> set zero 1e-20
  1317.  
  1318.    For more information,
  1319.  
  1320.         gnuplot> help set zero
  1321.  
  1322.    Q7.4: Gnuplot is plotting nothing when run via gnuplot <filename>!
  1323.           What can I do?
  1324.           Put a pause -1 after the plot command in the file.
  1325.  
  1326.    Q7.5: My formulas are giving me nonsense results! What's going on?
  1327.           Gnuplot does integer, and not floating point, arithmetic on
  1328.           integer expressions. For example, the expression 1/3 evaluates
  1329.           to zero. If you want floating point expressions, supply
  1330.           trailing dots for your floating point numbers. Example:
  1331.  
  1332.  
  1333.         gnuplot> print 1/3
  1334.                 0
  1335.         gnuplot> print 1./3.
  1336.                 0.333333
  1337.  
  1338.    This way of evaluating integer expressions is shared by both C and
  1339.           Fortran.
  1340.  
  1341.    Q7.6: My Linux gnuplot complains about a missing gnuplot_x11. What is
  1342.           wrong?
  1343.           The binary gnuplot distribution from sunsite.unc.edu and its
  1344.           mirrors in Linux/apps/math/gplotbin.tgz is missing one
  1345.           executable that is necessary to access the x11 terminal. Please
  1346.           install gnuplot from another Linux distribution, e.g.
  1347.           Slackware.
  1348.  
  1349.    Q7.7: set output 'filename' isn't outputting everything it should!
  1350.           You need to flush the output with a closing 'set output'.
  1351.  
  1352.   Section 8: Credits
  1353.  
  1354.    This list was initially compiled by John Fletcher with contributions
  1355.    from Russell Lang, John Campbell, David Kotz, Rob Cunningham, Daniel
  1356.    Lewart and Alex Woo. Reworked by Thomas Koenig from a draft
  1357.    by Alex Woo, with corrections and additions from Alex Woo, John
  1358.    Campbell, Russell Lang, David Kotz and many corrections from Daniel
  1359.    Lewart; Axel Eble and Jutta Zimmermann helped with the
  1360.    conversion to HTML.
  1361.  
  1362.  
  1363.  
  1364.     Thomas Koenig, ig25@rz.uni-karlsruhe.de, 1994-03-28
  1365.  
  1366. -- 
  1367. Thomas Koenig, Thomas.Koenig@ciw.uni-karlsruhe.de, ig25@dkauni2.bitnet.
  1368. The joy of engineering is to find a straight line on a double
  1369. logarithmic diagram.
  1370.