Please see the manual page for grDevices::dev.off(). Package rasterpdf overrides the function in order to provide functionality of raster_pdf(), but internally calls grDevices::dev.off().

dev.off(which = grDevices::dev.cur())

Arguments

which

An integer that specifies the device number. Default is the current device.

See also

Examples

raster_pdf(tempfile(fileext = ".pdf")) plot(iris) dev.off()
#> pdf #> 2