Description Usage Arguments Details
create_course_document
assumes that psPkgPath is a
directory that contains an R-package. By default the new
document is created in subdirectory "vignettes". If this
subdirectory does not exist, it is created. The document
is generated by the function rmarkdown::draft
using
the template "pdf_document".
1 2 3 | create_course_document(psDocuName, psPkgPath = ".",
psRmdTemplate = "pdf_document", psTemplatePkg = "rcoursetools",
psDocuSubdir = "vignettes", pbCreateSubdir = TRUE, pbEdit = TRUE)
|
psDocuName |
name of the new document |
psPkgPath |
path where package is located under which document should be created |
psRmdTemplate |
name of the template to be used |
psTemplatePkg |
package from where the template should be taken |
psDocuSubdir |
subdirectory in which document should be saved to |
pbCreateSubdir |
should new document be put in a separate subdirectory |
pbEdit |
directly open newly created document |
The basic functionality follows the function
devtools::use_vignette
, except for the possibility
of specifying any given template from any package. The template
can be specified via argument "psRmdTemplate". This requires
in the package given by psTemplatePkg that a subdirectory with
the name of the template exists under "rmarkdown/templates".
More information about setting up custom templates is obtained
in the helpfile of rmarkdown::draft.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.