.BG
.VE $Header: /usr/s/current/s/.help/RCS/par,v 1.6 87/02/04 09:27:57 rab Exp $
.FN par
.TL
par: Graphical Parameters
.CS
par(arg1, arg2, ...)
.PP
.AG argi
arguments in the `name='value form, where `name' is one of the
options below.
`argi' may also be a structure containing components whose names
match graphical parameter names given below.  Such a structure
is returned by the `query' function.
.PP
These are the graphical parameters which control the appearance of
graphical output.  There are three classes of parameters:
those which are available only through the high-level functions;
those which can appear in `par' or any graphical function;
and those which are available only through the `par' command.
.PP
If given through `par', the options are set permanently;
otherwise, they are reset at the end of the graphical operation.
.PP
Some of the most commonly used parameters are:
`cex=' character expansion,
`log=' logarithmic axes,
`lty=' line type,
`main=' main title,
`pch=' plotting character,
`type=' type of plot,
`xlab=' x axis label,
`ylab=' y axis label,
`xlim=' range for x axis,
and
`ylim=' range for y axis.
.PP
In the following lists of parameters,
the notation `"c"' denotes a character,
`"string"' denotes a character string, `i', `j', `m', and `n' are integers,
`L' is a logical value, and `x' is numeric.
.SH HIGH-LEVEL PARAMETERS
.PP
The following parameters may only be used in high-level graphical functions
(those that set up coordinate systems, e.g., `plot', `qqplot'),
.IP `axes=L'
if FALSE, suppresses all axis plotting (x, y axes and
box). Useful to make a high-level plotting routine generate
only the plot portion of the figure.
.IP `log="c"'
controls logarithmic axes.  Values "xy", "x", or "y"
produce log-log or log-x or log-y axes.
.IP `main="string"'
.br
main title for top of plot.  Plotted in characters of
size 1.5*`cex'.
.IP `sub="string"'
.br
sub-title, to be placed below the X-axis label in
standard sized characters.
.IP `type="c"'
type of plot desired.  Values are "p" for points, "l"
for lines, "b" for both points and lines (lines miss the points),
"o" for overlaid points and lines, "n" for no
plotting, and "h" for high-density vertical line plot.
.IP `xlab="string"'
.br
label for plotting below the x-axis.
.IP `xlim=c(x1,x2)'
.br
approximate minimum and maximum values to be put on x-axis.
These values are automatically rounded to make
them "pretty" for axis labelling.
.IP `ylab="string"'
see `xlab'.
.IP `ylim=c(x1,x2)'
see `xlim'.
.SH GENERAL PARAMETERS
.PP
The following parameters can be used in any graphical functions,
including `par'.
.IP `adj=x'
string justification parameter.  0 = left justify, 1 = right
justify, .5 = center.
.IP `bty="c"'
character representing the type of box.  Characters `o',
`l' (ell), `7', `c' will produce boxes which resemble the
corresponding upper-case letters.  The value `n' will
suppress boxes.
.IP `cex=x'
character expansion relative to device's standard size.  For
example, when `cex' = 2, characters are twice as big as
normal for the device.
.IP `col=x'
color, device dependent.
Default 1.  Generally, small integers are used to specify pen numbers
on pen plotters, color map indices on scope devices, etc.
On raster devices, the function `color' controls the color map.
.IP `crt=x'
character rotation in degrees measured counterclockwise from
horizontal.  When `srt' is set, `crt' is automatically set
to the same value.
.IP `csi=x'
character height (interline space) in inches.
.IP `err=x'
error mode: \-1 = do not print any error messages, 0 = print
messages.
.IP `font=x'
font to be used to plot characters.  Default 1 means the
default hardware font on the device.
The assignment of fonts to font numbers is done
through the `font' function.
.IP `lab=c(x,y,llen)'
.br
desired number of tick intervals on the X and Y axes
and the length of labels on both axes.
Default `c(5,5,7)'.
.IP `las=x'
style of axis labels.  0 = always parallel to axis (the default), 1 =
always horizontal, 2 = always perpendicular to axis.
.IP `lty=x'
line type, device dependent.  Normally type 1 is solid, 2
and up are dotted or dashed.
.IP `lwd=x'
line width, device dependent.  Normally type 1 is a standard
width line, smaller numbers give thinner lines, larger numbers
give thicker lines.  This parameter is unimplemented on
many devices; on pen plotters it is typically attained by
means of thicker pens which are selected by the `col' parameter.
.IP `mgp=c(x1,x2,x3)'
.br
margin parameters which give the margin coordinate for the
axis title, axis labels, and axis line.
Default is `c(3,1,0)'.
.IP `mkh=x'
height in inches of mark symbols drawn by the `mark='
argument to function `points'.
.IP `pch="c"'
the character to be used for plotting points.  If `pch' is a
period, a centered plotting dot is used.
If `pch' is an integer < 32 (or a character with an ASCII
value <32), it is taken as the number of a plotting symbol.
See documentation for `lines' for details.
.IP `smo=x'
smoothness of circles and other curves.  `smo' is the number
of rasters that the straight-line approximation to the curve
is allowed to differ from the exact position of the curve.
Large values produce more crude approximations to curves,
but allows the curves to be drawn with fewer line segments
and hence speeds up output.  The minimum number of line
segments that will be used for a circle is 8, regardless of
`smo'.
.IP `srt=x'
string rotation in degrees measured counterclockwise from
horizontal.  When specified, sets `crt' to same value.
.IP `tck=x'
the length of tick marks as a fraction of the smaller of the
width or height of the plotting region.  If `tck' is
negative, ticks are drawn outside of the plot region.  If
`tck' = 1, grid lines are drawn.
.IP `xaxp=c(ul,uh,n)'
.br
axis parameters giving coordinates of lower tick mark `ul',
upper tick mark `uh', and number of intervals `n' within the
range from `ul' to `uh'.
.IP `xaxs="c"'
style of axis interval calculation.  The styles "s" and "e"
set up standard and extended axes, where numeric axis labels
are more extreme than any data values.  In addition,
extended axes may be extended another character width so
that no data points lie very near the axis limit.  Style "i"
creates an axis labelled internal to the data values.  This
style wastes no space, yet still gives pretty labels.
Style "r" extends the data range by 7% on each end, and then labels the
axis internally.  This ensures that all plots take up a fixed percent
of the plot region, yet keeps points away from the axes.
Style "d" is a direct axis, and axis parameters will not be
changed by further high-level plotting routines.  This is
used to "lock-in" an axis from one plot to the next.
Default is "e".
.IP `xaxt="c"'
axis type.  Type "n" (null) can be used to cause an axis to
be set up by a high-level routine, but then not plotted.
.IP `xpd=L'
logical value controlling clipping.  Values: FALSE means no
points or lines may be drawn outside of the plot region.
TRUE means points, lines, and text may be plotted outside of the
plot region as long as they are inside the figure region.
.IP `yaxp=c(ul,uh,n)'
see `xaxp'.
.IP `yaxs="c"'
see `xaxs'.
.IP `yaxt="c"'
see `xaxt'.
.SH LAYOUT PARAMETERS
.PP
The following parameters may only be used in function `par', because
they change the overall layout of plots or figures.
.IP `fig=c(x1,x2,y1,y2)'
.br
coordinates of figure region expressed as fraction of
device surface.
.IP `fin=c(w,h)'
.br
width and height of figure in inches.
.IP `fty="c"'
figure type.  Default "m", the maximum size that will fit on the
device.
.IP `mai=c(x1,x2,x3,x4)'
.br
margin size specified in inches.  Values given for
bottom, left, top, and right margins in that order.
.IP `mar=c(xbot,xlef,xtop,xrig)'
.br
maximum value for margin coordinates on each side of
plot.  Margin coordinates range from 0 at the edge of the
box outward in units of `mex' sized characters.  If the
margin is respecified by `mai' or `mar', the plot region is
re-created to provide the appropriate sized margins within
the figure.  Default value is `c(5.1,4.1,4.1,2.1)'.
.IP `mex=x'
the coordinate unit for addressing locations in the
margin is expressed in terms of `mex'.  `mex' is a character
size relative to default character size (like `cex') and
margin coordinates are measured in terms of characters of
this size.
.IP `mfg=c(i,j,m,n)'
.br
multiple figure parameters which give the row and column
number of the current multiple figure and the number of rows
and columns in the current array of multiple figures.
.IP `mfrow=c(m,n)'
.br
subsequent figures will be drawn row-by-row
in an `m' by `n' matrix on the page.
.IP `mfcol=c(m,n)'
.br
subsequent figures will be drawn column-by-column
in an `m' by `n' matrix on the page.
.IP `new=L'
if TRUE, the current plot is assumed to have no
previous plotting on it.
Any points, lines, or text will set `new' FALSE.
.IP `oma=c(x1,x2,x3,x4)'
.br
specification of the outer margin coordinates in terms
of text of size `mex'.  `oma' provides the maximum value for
outer margin coordinates on each of the four sides of the
multiple figure region.  `oma' causes recreation of the
current figure within the confines of the newly specified
outer margins.
.IP `omd=c(x1,x2,y1,y2)'
.br
the region within the outer margins (which is to be used
by multiple figure arrays) is specified by `omd' as a
fraction of the entire device.
.IP `omi=c(x1,x2,x3,x4)'
.br
size of outer margins in inches.
.IP `pin=c(w,h)'
.br
width and height of plot, measured in inches.
.IP `plt=c(x1,x2,y1,y2)'
.br
the coordinates of the plot region measured as a
fraction of the figure region.
.IP `pty="c"'
the type of plotting region currently in effect.
Values: "s" generates a square plotting region; "m" (the default)
generates a maximal size plotting region, which, with the
margins, completely fills the figure region.
.IP `usr=c(x1,x2,y1,y2)'
.br
user coordinate limits (min and max) on X and Y axes.
Default, when device is initialized, is `c(0,1,0,1)'.
.KW plot*
.KW dplot*
.KW hplot*
.KW graphical parameters
.WR
