R/nko_slides.R

Defines functions nko_slides

Documented in nko_slides

#' A Function to knit NKO Markdown Reports to MS Word format
#'
#' This function knits the NKO R Markdown to MS Word format, with NKO Themes.
#' @param toc	TRUE to include a table of contents in the output
#' @param fig_width	Default width (in inches) for figures
#' @param fig_height	Default width (in inches) for figures
#' @param fig_caption	TRUE to render figures with captions
#' @param df_print	Method to be used for printing data frames. Valid values include "default", "kable", "tibble", and "paged". The "default" method usesprint.data.frame. The "kable" method uses the knitr::kablefunction. The "tibble" method uses the tibble package to print a summary of the data frame. The "paged" method creates a paginated HTML table (note that this method is only valid for formats that produce HTML). In addition to the named methods you can also pass an arbitrary function to be used for printing data frames. You can disable the df_print behavior entirely by setting the option rmarkdown.df_print to FALSE.
#' @param smart  Produce typographically correct output, converting straight quotes to curly quotes, — to em-dashes, – to en-dashes, and ... to ellipses.
#' @param keep_md	Keep the markdown file generated by knitting.
#' @param md_extensions	Markdown extensions to be added or removed from the default definition or R Markdown. See the rmarkdown_format for additional details.
#' @param reference_doc	Path to a PowerPoint template.
#' @param pandoc_args	Additional command line options to pass to pandoc
#' @keywords nko
#' @export
#' @examples
#' nko_slides()

nko_slides <- function(
  toc = FALSE,
  fig_width = 5,
  fig_height = 4,
  fig_caption = TRUE,
  df_print = "kable",
  smart = TRUE,
  md_extensions = NULL,
  keep_md = FALSE,
  reference_doc = system.file("rmarkdown/templates/resources/Presentation_Template_2017_10_15.pptx", package = "NKOMarkdownTemplate"),
  pandoc_args = NULL
  ) {
  # call the rmarkdown::powerpoint_presentation function
  rmarkdown::powerpoint_presentation(
    toc = toc,
    fig_width = fig_width,
    fig_height = fig_height,
    fig_caption = fig_caption,
    df_print = df_print,
    smart = smart,
    keep_md = keep_md,
    md_extensions = md_extensions,
    reference_doc = reference_doc,
    pandoc_args = pandoc_args
  )
}
newknowledgeorg/NKOMarkdownTemplate documentation built on Oct. 3, 2020, 11:17 p.m.