setup_knitr_for_grattex: Setup knitr for Grattan reports

Description Usage Arguments Value

Description

Setup knitr for Grattan reports

Usage

1
2
3
4
setup_knitr_for_grattex(chunktimings.txt = "CHUNKTIMINGS.txt",
  bundle_chart_data = FALSE, theGlobalEnv = .GlobalEnv,
  chunktimings_width = 5, alignAllowedExtra = c("R", "N"),
  halt_if_xtable_unattached = NULL, error = FALSE)

Arguments

chunktimings.txt

The file to write chunk timings

bundle_chart_data

Whether or not to bundle chart data.

theGlobalEnv

Must be .GlobalEnv.

chunktimings_width

Passed to format the number of characters to display in the chunktimings time field. By default, 5, which allows less than 1000 seconds per chunk.

alignAllowedExtra

A character vector of single characters to add as permitted values to pass to the align argument to xtable. By default, c("R", "N") to avoid spurious warnings when these are used.

halt_if_xtable_unattached

If TRUE, xtable must be attached when the function is called. If NULL, the default a message is printed recommending it be attached. It should be attached so that the parts of this function affecting xtable have a chance of being effected. If FALSE, neither an error nor a message is given.

error

Passed to knitr::opts_chunk$set(error = < >). By default, FALSE, so that errors in chunks halt compilation.

Value

Called for its side-effect: when knitr is in progress, sets up knitr for consistent formatting.


HughParsonage/grattanCharts documentation built on May 8, 2019, 10:52 a.m.