Save an object as RDS and create a download button that can be rendered to Rmarkdown HTML pages. Uses the package downloadthis.
download_button(
object,
save_output = FALSE,
outfile_dir = NULL,
filename = NULL,
button_label = paste0("Download: ", "<code>", filename, "</code>"),
output_extension = ".rds",
icon = "fa fa-save",
button_type = "success",
self_contained = TRUE,
add_download_button = TRUE,
verbose = TRUE
)
R object to serialize.
Default FALSE. If TRUE, all outputs (tables and plots) of the analysis will be saved in a folder (EpiCompare_file).
Directory to save the file to.
Name of the file to save.
Character (HTML), button label
Extension of the output file. Currently, .csv
,
.xlsx
, and .rds
are supported. If a (named) list is passed to the
function, only .xlsx
and .rds
are supported.
Fontawesome tag e.g.: "fa fa-save"
Character, one of the standard Bootstrap types
A boolean to specify whether your HTML output is
self-contained. Default to FALSE
.
Add download buttons for each plot or dataset.
Print messages.
Download button as HTML text.
button <- download_button(object=mtcars)