DAAG (version 1.24)

hardcopy: Graphical Output for Hardcopy

Description

This function streamlines graphical output to the screen, pdf or ps files. File names for hard copy devices can be generated automatically from function names of the form g3.2 or fig3.2 (the choice of alphabetic characters prior to 3.2 is immaterial).

Usage

hardcopy(width = 3.75, height = 3.75, color = FALSE, trellis = FALSE,
                 device = c("", "pdf", "ps"), path = getwd(), file =
                 NULL, format = c("nn-nn", "name"), split = "\\.",
                 pointsize = c(8, 4), fonts=NULL, horiz = FALSE, ...)

Arguments

width

width of plot in inches (sic!)

height

height of plot in inches (sic!)

color

(lattice plots only) TRUE if plot is not black on white only

trellis

TRUE if plot uses trellis graphics

device

screen "", pdf or ps

path

external path name

file

name of file to hold output, else NULL

format

Alternatives are "nn-nn" and "name".

split

character on which to split function name (file=NULL)

pointsize

Pointsize. For trellis devices a vector of length 2 giving font sizes for text and for points respectively

fonts

For postscript devices, specify families that will be used in addition to the intial device

horiz

FALSE for landscape mode; applies only to postscript files

...

Other arguments for passing to the pdf or postscript

Value

Graphical output to screen, pdf or ps file.

Details

If a file name (file, without extension) is not supplied, the format argument determines how the name is constructed. With format="name", the function name is used. With format="nn-nn" and dotsplit unchanged from the default, a function name of the form g3.1 leads to the name 03-01. Here g can be replaced by any other non-numeric characters; the result is the same. The relevant extension is in any case added.

See Also

postscript