Graph (Unix)

Short description: Unix graphing utility

graphOriginal author(s)| Douglas McIlroy
(AT&T Bell Laboratories)

|

Developer(s)| Various open-source and commercial developers
Operating system| Unix, Unix-like
Platform| Cross-platform
Type| Command

In Unix, graph is a command-line utility used to draw plots from tabular data.

## Contents

* 1 History
* 2 Usage
* 3 Example (Unix)
* 4 Example (GNU plotutils)
* 5 References
* 6 External links

## History

The graph utility, written by Douglas McIlroy, was present in the first version of Unix, and every later version, for instance:

* Unix Version 7, released in 1979 [1]
* SunOS 5.10, the Solaris version released in 2005 [2]

Its output is a sequence of commands for the plot utility, which creates plots using ASCII graphics.

This design demonstrates the Unix philosophy: defining the plot (graph) and drawing it (plot) are separate tools, so they can be recombined with other tools. For instance, plot can be substituted with a different utility, that accepts the same plot commands, but creates the plot in a graphics file format, or sends it to a plotter.

Unix v7 also provided device drivers for plotting the results to various graphics devices; [3] this was announced as now standard.[4]

The GNU plotutils package provides a free non-exact reimplementation, available for Linux and many other systems. It can create plots in various graphics formats.

## Usage

In its simplest use, the graph utility takes a textfile containing pairs of numbers, indicating the points of a line plot.

It outputs the line plot. Several options can be supplied to modify its behavior.

## Example (Unix)

* Preparing example input and running graph with plot

* The results

These screenshots demonstrate basic operation on SunOS 5.10, on which graph and plot come preinstalled. The example input is from the first example in the GNU plotutils manual.

## Example (GNU plotutils)

* Preparing example input and running graph in Tektronix mode

* The results

These screenshots demonstrate the GNU plotutils version of graph when run in an xterm, exploiting xterm's ability to emulate a Tektronix 4010 plotter.

This demo was run on Ubuntu, which makes GNU plotutils available as an optional package; many other Linux distributions and other Unix-like systems do the same.

## References

1. ↑ "graph". Bell Labs. 1979. https://www.unix.com/man-page/v7/1G/GRAPH/.
2. ↑ "graph". Sun Microsystems. 2005. https://www.unix.com/man-page/sunos/1/graph/.
3. ↑ Herrmann, Robert B., ed (2004). Computer programs in Seismology: CALPLOT graphics. p. vi. http://www.eas.slu.edu/eqc/eqc_cps/CPS/CPS330/cps330p.pdf. Retrieved Nov 24, 2018.
4. ↑ "7th Edition UNIX — Summary". Murray Hill, New Jersey 07974: Bell Laboratories. September 6, 1978. p. 1. http://a.papnet.eu/UNIX/v7/files/doc/01_summary.pdf.

## External links

* v
* t
* e

Unix command-line interface programs and shell builtins

File system|

* cat
* chmod
* chown
* chgrp
* cksum
* cmp
* cp
* dd
* du
* df
* file
* fuser
* ln
* ls
* mkdir
* mv
* pax
* pwd
* rm
* rmdir
* split
* tee
* touch
* type
* umask

Processes|

* at
* bg
* crontab
* fg
* kill
* nice
* ps
* time

User environment|

* env
* exit
* logname
* mesg
* talk
* tput
* uname
* who
* write

Text processing|

* awk
* basename
* comm
* csplit
* cut
* diff
* dirname
* ed
* ex
* fold
* head
* iconv
* join
* m4
* more
* nl
* paste
* patch
* printf
* sed
* sort
* strings
* tail
* tr
* uniq
* vi
* wc
* xargs

Shell builtins|

* alias
* cd
* echo
* test
* unset
* wait

Searching|

* find
* grep

Documentation|

* man

Software development|

* ar
* ctags
* lex
* make
* nm
* strip
* yacc

Miscellaneous|

* bc
* cal
* expr
* lp
* od
* sleep
* true and false

* Categories
* Standard Unix programs
* Unix SUS2008 utilities
* List

0.00

(0 votes)

Original source: https://en.wikipedia.org/wiki/Graph (Unix). Read more

|

Retrieved from "https://handwiki.org/wiki/index.php?title=Software:Graph_(Unix)&oldid=779677"
*[v]: View this template
*[t]: Discuss this template
*[e]: Edit this template