open_graphics_device: Open a graphics device based on a file name

View source: R/plots.R

open_graphics_deviceR Documentation

Open a graphics device based on a file name

Description

open_graphics_device takes a file name and opens a graphics device based on the file suffix. Defaults to pdf if no match is found. If the file suffix is .svg then open_graphics_device tries to use the svglite package. If svglite is not installed, it uses the builtin svg

Usage

open_graphics_device(filename = "plot.pdf", ...)

Arguments

filename

character, the filename to use

...

Arguments passed on to the graphics device

Value

TRUE invisibly

Examples

open_graphics_device(filename = 'plot.eps')
open_graphics_device(filename = 'plot.eps', width = 6, height = 5)
open_graphics_device(filename = 'plot.png', width = 640, height = 480)


richysix/miscr documentation built on March 24, 2023, 5:24 a.m.