save_plots: Save plots by name

View source: R/utils.R

save_plotsR Documentation

Save plots by name

Description

Save plots by name

Usage

save_plots(plots, save_path = NULL, type = "png", ...)

Arguments

plots

A named list of ggplot2 plots.

save_path

A character string indicating where to save plots if required.

type

A character string indicating the format to use to save plots.

...

Additional arguments passed to ggplot2::ggsave()

See Also

Plotting functions add_forecast_dates(), plot.fv_forecast(), plot.fv_posterior(), plot_cases(), plot_default(), plot_growth(), plot_pairs(), plot_posterior(), plot_rt(), plot_theme(), plot_voc_advantage(), plot_voc_frac()

Examples

posterior <- fv_example(strains = 2, type = "posterior")
p <- plot(posterior, type = "all")
save_plots(p, save_path = tempdir())

epiforecasts/forecast.vocs documentation built on May 14, 2023, 2 p.m.