knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)
# rmdhelp::show_knit_hook_call()
knitr::knit_hooks$set(hook_convert_odg = rmdhelp::hook_convert_odg)
library(qrmdreport)

Disclaimer

The way how to use the package qrmdreport to produce project reports based on a given template is described.

Package Installation

The first step is to install the package qrmdreport.

remotes::install_github(repo = 'pvrqualitasag/qrmdreport')

New Report Using RStudio

After the installation, a new report based on the template in qrmdreport can be created using File -> New File -> RMarkdown -> From Template -> Qualitas AG Project Report.

#rmdhelp::use_odg_graphic(ps_path = 'odg/rstudio-new-report.odg')
knitr::include_graphics(path = "odg/rstudio-new-report.png")

From R Console

A new report can also be generated from the R Console using the command

rmarkdown::draft(file = 'report1', package = 'qrmdreport', template = 'qprojectreport', create_dir = TRUE)

This creates a new RMarkdown file called report1.Rmd in a new subdirectory called report1. This can then be edited and knit to a pdf-document.

Wrapper Functions

The following wrapper functions are available in this package 'qrmdreport'

# slides
qrmdreport::draft_qbeamerslides(ps_path = '20210216_test_slides_no_rmd')
qrmdreport::draft_qbeamerslides(ps_path = '20210216_test_slides_with_rmd.Rmd')

# empty doc
qrmdreport::draft_qemptydoc(ps_path = '20210216_test_empty_no_rmd')
qrmdreport::draft_qemptydoc(ps_path = '20210216_test_empty_with_rmd.Rmd')

# generic doc
qrmdreport::draft_qgenericdoc(ps_path = '20210216_test_generic_no_rmd')
qrmdreport::draft_qgenericdoc(ps_path = '20210216_test_generic_with_rmd.Rmd')

# report
qrmdreport::draft_qprojectreport(ps_path = '20210216_test_report_no_rmd')
qrmdreport::draft_qprojectreport(ps_path = '20210216_test_report_with_rmd.Rmd')


pvrqualitasag/qrmdreport documentation built on April 17, 2021, 6:37 a.m.