Custom RMarkdown template in Dataiku
DataR11
Registered Posts: 2 ✭
Would it be possible to use a custom RMarkdown template from an internal package in Dataiku?
Answers
-
thanks,
I have found a solution to do it
1: Import the package containing the Rmarkdown template into a folder
2: call the package with load_all
library(dataiku)
Packages <- dkuManagedFolderPath("nki5z2ng")
devtools::load_all(paste0(Packages,"/Template"))
3. create your Rmardown "test.Rmd" using the template.
---
title: "test"
output:
Template::template_name:
self_contained: True
number_sections: Falseknit: pagedown::chrome_print
---4.rmarkdown::render(paste0(Packages,"/test.Rmd"),
output_dir = paste0(Packages,"/"),
output_file="test")