Add an NSSP RMarkdown template report to extend an existing installation of the Rnssp package.
add_rmd_template( template = NULL, pkg = "Rnssp", restart = TRUE, verbose = TRUE )
template | a character string with the name of a single template name.
The template name must be one of the elements of the vector returned
by |
---|---|
pkg | a character string with the name of a single package. An error occurs if more than one package name is given. |
restart | logical. Should R session be restarted after template installation? (default is TRUE) |
verbose | logical. Should alert session restart message be printed? |
a character string
In interactive mode, this utility function prompts the user to select an
Rmarkdown template .zip file when the template
argument is not
specified or set to NULL
.
In non-interactive mode, this utility function prompts the user to specify a
path to an Rmarkdown template .zip file when the template
argument
is not specified or set to NULL
.
When the template
is specified, regardless of the pkg
argument,
this utility function download the specified template from the
Rnssp-rmd-templates Github repository.
When the specified template name is not available, it throws an error.
if (FALSE) { add_rmd_template() # Add a new Rmd template to the 'Rnssp' package add_rmd_template(pkg = "rmarkdown") # Add a new Rmd template to the 'rmarkdown' package add_rmd_template("text_mining") # Add the 'text_mining' template report to the Rnssp package }