renderReport.Rd
Render the technical report file to the specified output format using pandoc.
renderReport(sysargs, fileName ="SPR_Report",
rmd_title = "SPR workflow Template - Report",
rmd_author = "Author",
rmd_date= "Last update: `r format(Sys.time(), '%d %B, %Y')`",
type = c("html_document"),
desc = "This is a workflow template.",
quiet = FALSE, open_file = TRUE)
object of class SYSargsList
.
character string naming a file output. Default is "spr_report.Rmd"
.
string, title of the Rmd.
string, author(s) of the Rmd, put all authors in a single character string.
string, date header of Rmd.
The R Markdown output format to convert to. The option
can be the name of a format (e.g. "pdf_document"
or "html_document"
).
string, or character vector of strings, some description text in format Rmarkdown that will be added to the document before the workflow steps start. It can be a single line or multiple lines by providing a character vector, each item is one line.
If set to TRUE
, all messages returned by the function will be suppressed.
Default is TRUE
.
It will return an SYSargsList
updated, with the file path location.
See also as SYSargsList-class
.
sal <- SPRproject(overwrite = TRUE)
#> Recreating directory '/home/runner/work/systemPipeR/systemPipeR/docs/reference/.SPRproject'
#> Creating file '/home/runner/work/systemPipeR/systemPipeR/docs/reference/.SPRproject/SYSargsList.yml'
file_path <- system.file("extdata", "spr_simple_wf.Rmd", package = "systemPipeR")
sal <- importWF(sal, file_path = file_path, verbose = FALSE)
#> Now check if required tools are installed
#> Check if they are in path:
#> Checking path for gzip
#> PASS
#> Checking path for gunzip
#> PASS
#> step_name tool in_path
#> 1 gzip gzip TRUE
#> 2 gunzip gunzip TRUE
#> All required tools in PATH, skip module check. If you want to check modules use `listCmdModules`
targetspath <- system.file("extdata/cwl/example/targets_example.txt", package = "systemPipeR")
appendStep(sal) <- SYSargsList(step_name = "echo",
targets = targetspath, dir = TRUE,
wf_file = "example/workflow_example.cwl", input_file = "example/example.yml",
dir_path = system.file("extdata/cwl", package = "systemPipeR"),
inputvars = c(Message = "_STRING_", SampleName = "_SAMPLE_"))
sal <- renderReport(sal, open_file = FALSE)
#> Step name echo exist in SYSargsList but not in template.
#> It will be added as a new step in report, consider add it to your template first, and then use `sal <- importWF(sal, 'xx.Rmd', update = TRUE)` to update the template first before rendering report.
#>
#> Attaching package: ‘BiocStyle’
#> The following object is masked from ‘package:systemPipeR’:
#>
#> output
#>
#>
#> processing file: SPR_Report.Rmd
#>
|
| | 0%
|
|.... | 7%
|
|....... | 13% (setup)
|
|........... | 20%
|
|............... | 27% (load_library)
|
|.................. | 33%
|
|...................... | 40% (export_iris)
|
|.......................... | 47%
|
|............................. | 53% (gzip)
|
|................................. | 60%
|
|..................................... | 67% (gunzip)
|
|........................................ | 73%
|
|............................................ | 80% (stats)
|
|................................................ | 87%
|
|................................................... | 93% (echo)
|
|.......................................................| 100%
#> output file: SPR_Report.knit.md
#> /usr/bin/pandoc +RTS -K512m -RTS SPR_Report.knit.md --to html4 --from markdown+autolink_bare_uris+tex_math_single_backslash --output SPR_Report.html --lua-filter /home/runner/work/_temp/Library/bookdown/rmarkdown/lua/custom-environment.lua --lua-filter /home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/pagebreak.lua --lua-filter /home/runner/work/_temp/Library/rmarkdown/rmarkdown/lua/latex-div.lua --self-contained --wrap preserve --variable bs3=TRUE --section-divs --table-of-contents --toc-depth 3 --variable toc_float=1 --variable toc_selectors=h1,h2,h3 --variable toc_collapsed=1 --variable toc_smooth_scroll=1 --variable toc_print=1 --template /tmp/Rtmp7ygQ4c/BiocStyle/template.html --no-highlight --variable highlightjs=1 --number-sections --variable theme=bootstrap --css /home/runner/work/_temp/Library/BiocStyle/resources/html/bioconductor.css --mathjax --variable 'mathjax-url=https://mathjax.rstudio.com/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML' --include-in-header /tmp/Rtmp7ygQ4c/rmarkdown-str486d3653a4e.html --variable code_folding=show --variable code_menu=1
#>
#> Output created: SPR_Report.html
#> Success! Report created at SPR_Report.html