Description Usage Arguments Value Author(s) References Examples
searches in several directories for files with Rmd suffix. Skip some file names that contain strings in ar_spn_skip. Save output rendered HTML and PDF files to a directory. And control if to render Rmd to PDF, HTML as well as R.
1 2 3 4 5 6 7 8 9 10 11 | ff_sup_rmd2htmlpdfr(
ar_spt_root = c("C:/Users/fan/R4Econ/amto/array/",
"C:/Users/fan/R4Econ/math/integration"),
ar_spn_skip = c("basics", "integrate"),
st_rmd_suffix_pattern = ".Rmd",
st_save_add_suffix = "",
spt_out_directory = "C:/Users/fan/downloads",
bl_recursive = TRUE,
ls_bool_convert = list(bl_pdf = TRUE, bl_html = TRUE, bl_R = TRUE),
bl_verbose = TRUE
)
|
ar_spt_root |
array of string paths of folders to search in |
ar_spn_skip |
array a string array of names, if path found contains any of the string in the array, will skip. |
st_rmd_suffix_pattern |
string name of file suffix to search over |
st_save_add_suffix |
string suffix to add to rendered html, pdf files |
spt_out_directory |
string full path of where to store the rendered html, pdf, r files |
bl_recursive |
boolean if to search in folders recursively |
ls_bool_convert |
list of booleans to generate pdf, html and or R file. Generate only HTML for example. considered included, searched and found |
bl_verbose |
verbose printing more |
a list of string paths of files generated
ls_spt_pdf_generated - a list of pdf file names
ls_spt_html_generated - a list of html file names
ls_spt_R_generated - a list of R file names generated
#'
Fan Wang, http://fanwangecon.github.io
https://fanwangecon.github.io/R4Econ/development/inout/htmlpdfr/fs_rmd_pdf_html.html https://github.com/FanWangEcon/REconTools/blob/master/R/ff_sup_inout.R
1 2 3 4 5 6 7 8 9 10 | ar_spt_root <- c('C:/Users/fan/R4Econ/support/rmd')
ar_spn_skip <- c('matrix', 'tibble', '_main')
spt_out_directory <- 'C:/Users/fan/downloads'
st_save_add_suffix <- '_newsave'
ls_bool_convert <- list(bl_pdf=TRUE, bl_html=TRUE, bl_R=TRUE)
bl_verbose <- TRUE
ff_sup_rmd2htmlpdfr(ar_spt_root=ar_spt_root, ar_spn_skip=ar_spn_skip,
spt_out_directory=spt_out_directory, st_save_add_suffix=st_save_add_suffix,
ls_bool_convert=ls_bool_convert,
bl_verbose=bl_verbose)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.