yaml_header: Functions for YAML comments

Description Usage Arguments Value Examples

View source: R/yaml.R

Description

A facility for generating a comment block for inserting at the top of an R script to insert a yaml header and for setting chunk options within scripts to use the RStudio facility for automatically rendering scripts into documents.

Usage

1
2
3

Arguments

title

A character string; if omitted may be supplied via the console

author

A character string; if omitted may be supplied via the console

...

Extra arguments, for yaml_header currently ignored; for chunk_options comma separated chunk options

Value

An incomplete yaml header, or a line of chunk options, in the clipboard by default

Examples

1
2
3
4
5
6
yaml_header(title = "My script",
            author = "Bill Venables")
chunk_options(comment="",
              fig.height=7,
              fig.width=8,
              out.width="90%")

bannerCommenter documentation built on March 23, 2021, 9:06 a.m.