View source: R/plot_wrappers.R
as.pngpdf | R Documentation |
Wrapper around gglplot2::ggsave with presets.
as.pngpdf(
filename,
plot = ggplot2::last_plot(),
scale = 1,
width = 12,
height = 8,
units = "in",
dpi = 400
)
filename |
File name to create on disk. |
plot |
Plot to save, defaults to last plot displayed. |
scale |
Multiplicative scaling factor. |
width , height |
Plot size in units expressed by the |
units |
One of the following units in which the |
dpi |
Plot resolution. Also accepts a string input: "retina" (320), "print" (300), or "screen" (72). Applies only to raster output types. |
A plot saved as .png and .pdf, returns nothing.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.