plot_render | R Documentation |
Saving a plot (i.e. ggplot object) to an image file
plot_render(
plot_obj,
img_name = NULL,
img_format = "png",
img_dir = getwd(),
img_save = FALSE,
opts = NULL
)
plot_obj |
A plot object or function |
img_name |
File name |
img_format |
Image file format |
img_dir |
Output file directory |
img_save |
Logical for saving a plot in a file or not (default) |
opts |
a knitr::opts_chunk object containing all above img_* arguments values as elements |
a plot object
## Not run:
plot_render(plot_obj)
plot_render(plot_obj, img_name = "myimage", img_save = TRUE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.