R.utils (version 1.6.4)

devEval: Opens a new device, evaluate (graphing) code, and closes device

Description

Opens a new device, evaluate (graphing) code, and closes device.

Usage

devEval(type=getOption("device"), expr, envir=parent.frame(), name="Rplot", tags=NULL, ..., ext=substitute(type), filename=sprintf("%s.%s", paste(c(name, tags), collapse = ","), ext), path="figures/", force=TRUE)

Arguments

type
Specifies the type of device to be used by devNew.
expr
The expression of graphing commands to be evaluated.
envir
The environment where expr should be evaluated.
name, tags
The fullname name of the image is specified as the name with optional comma-separated tags appended.
ext
The filename extension of the image file generated, if any. By default, it is inferred from argument type.
...
Additional arguments passed to devNew.
filename
The filename of the image saved, if any. See also below.
path
The directory where then image should be saved, if any.
force
If TRUE, and the image file already exists, then it is overwritten, otherwise not.

Value

  • Returns a named list with items specifying for instance the pathname, the fullname etc of the generated image. Note that the return value may be changed in future releases.

Generated image file

If created, the generated image file is saved in the directory specfied by argument path with a filename consisting of the name followed by optional comma-separated tags and a filename extension given by argument ext.

See Also

devNew().