View source: R/multiple_plots.R
bro_ggsave_paged | R Documentation |
This function takes a ggplot (for single page) or list of ggplots (for multi page) and writes them to file.
In case the input has absolute dimensions (e.g. as a result of egg::set_panel_size()
or
patchwork::plot_layout()
), width and height of the output are adjusted to fit the content.
bro_ggsave_paged(
gg = last_plot(),
filename,
device = NULL,
path = NULL,
scale = 1,
width = NA,
height = NA,
units = "mm",
dpi = 300,
limitsize = TRUE,
return_input = FALSE,
burst_to_multiple_files = FALSE,
...
)
gg |
ggplot or list of ggplots |
filename |
Filename for export |
device |
Device to use. Can either be a device function (e.g. |
path |
Path to save plot to (combined with filename). |
scale |
Multiplicative scaling factor. |
width, height, units |
Plot size in |
dpi |
Plot resolution. Also accepts a string input: "retina" (320), "print" (300), or "screen" (72). Applies only to raster output types. |
limitsize |
When TRUE (the default), ggsave will not save images larger than 50x50 inches, to prevent the common error of specifying dimensions in pixels. |
return_input |
If |
... |
Other arguments passed on to the graphics device function, as specified by device. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.