Package-wide helper used by the vignettes to persist a table to
a per-vignette res/res_<topic>/ folder. Writes a .tex file and, when a
data frame is supplied, a companion .csv. Saving is gated by bl_save
so a vignette can keep all outputs off by default and flip individual
tables on through its ls_save_res control list.
Arguments
- kbl_latex
A
kableExtra/knitr_kableobject or character vector built withformat = "latex"; coerced withas.character()before writing.- name
File stem (no extension) for the
<name>.tex/<name>.csvfiles.- spt_res
Destination folder; created recursively if missing.
- df
Optional data frame; when supplied, also written as
<name>.csv.- bl_save
If
FALSE, do nothing (control switch). DefaultTRUE.
Author
Fan Wang, http://fanwangecon.github.io