View source: R/generate_output.R
| generate_output | R Documentation |
Generate output in specified format (e.g., xlsx, html, pdf, word)
generate_output(data, path, ..., format = c("xlsx", "html", "pdf", "word"))
data |
Preferably a |
path |
File path to save the output. |
... |
Additional arguments passed to specific format functions. |
format |
Output format. One of |
Generates and saves the output file in the specified format at the given path.
#' # Generate an xlsx file from a tsg object
data <- generate_frequency(dplyr::starwars, sex)
dir_to <- tempdir()
generate_output(
data,
file.path(dir_to, "starwars_frequency.xlsx"),
format = "xlsx"
)
unlink(file.path(dir_to, "starwars_frequency.xlsx"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.