tab_notes: Form table notes

View source: R/table-notes.R

tab_notesR Documentation

Form table notes

Description

Form table notes

Usage

tab_notes(
  notes = character(0),
  escape_fun = tab_escape,
  note_config = noteconf(type = "tpt"),
  r_file = getOption("mrg.script", NULL),
  r_file_label = "Source code: ",
  output_file = NULL,
  output_file_label = "Source file: ",
  output_dir = getOption("pmtables.dir"),
  path.type = getOption("pmtables.path.type", "none"),
  ...
)

Arguments

notes

a character vector of notes to include at the foot of the table; use r_file and output_file for source code and output file annotations; see tab_notes() for arguments to pass in order to configure the way notes appear in the output; see also st_notes()

escape_fun

a function passed to prime_fun that will sanitize column data

note_config

a noteconf() object used to configure how table notes are displayed; see also st_noteconf().

r_file

the name of the R file containing code to generate the table; the file name will be included in the notes in the table footer; see also st_files().

r_file_label

a prefix for r_file.

output_file

the name of the output file where the table text will be saved; the file name will be included in the notes in the table footer; see also st_files().

output_file_label

a prefix for output_file.

output_dir

directory location where output .tex file is saved; defaults to working directory.

path.type

whether to include the path to the output file in the table notes and how to format it; options include "none", "proj", and "raw"; see format_table_path().

...

not used.

Examples

tab <- stable(
  stdata(),
  note_config = noteconf(type = "mini")
)


metrumresearchgroup/pmtables documentation built on Oct. 27, 2024, 5:16 p.m.