positron icon indicating copy to clipboard operation
positron copied to clipboard

Rendering with RMarkdown "knit" option in YAML header

Open ncbss opened this issue 1 year ago • 0 comments

In RStudio, I have the code below in the YAML header to customize the output file location and its name, e.g., add a date a specific name to the PDF output. I noticed that this doesn't seem to work for Positron. Would there be a different of achieving the same?

knit: (function(inputFile, encoding) { rmarkdown::render(inputFile, encoding = encoding, output_file = paste('../output/Main Analysis_', format(Sys.Date(),'%Y%m%d'),'.pdf', sep='')) })

Thank you

ncbss avatar Jul 06 '24 05:07 ncbss