The values a spec may hold that are not plain data, and the pieces a report is made of:
Usage
tfl_r(code)
tfl_unset()
tfl_call(fn, args = list(), package = NULL)
tfl_item(fn, args = list(), from = "own")
tfl_output(
id,
kind = c("table", "figure", "listing"),
label = NA_character_,
population = NA_character_,
extends = "defaults",
data = NULL,
codelists = list(),
content = list(),
page = list(),
ard = NULL,
template = NULL,
style = NULL
)Arguments
- code
One string of R code.
- fn
A function's name (
plan_cells,cards::ard_summary,rtf_border).- args
The arguments, a named list.
- package
The package
fnis in, when its name does not say.- from
Where an item came from:
"own","defaults","pattern:<name>","style:<name>","template:<name>".- id
The report's id (letters, digits,
.,_,-); the file isspec/outputs/<id>.yml.- kind
"table","figure"or"listing".- label, population
The report's label and analysis set (
NA: none).- extends
The files layered under this one, nearest first (
"defaults","patterns/<name>");"none"for none.- data
What the report reads, its step 1 (a list:
source–"ard","code"or"dataset"– andobject,steps,code,dataset...).- codelists
The report's code lists, by variable.
- content
The layers, a list of
tfl_item.- page
The document:
titles,footnotes,header,footer(maps by line),tokens, and thertf_*calls' arguments.- ard
The report's part of the study ARD, made in the ARD stage before any report (a list:
analysis_data,analyses);NULLnone.- template
A template SPEC,
list(name = , args = ): the report is the template's items (tfl_templates()) withard,dataandcontentadding to them or changing them (tfl_resolve_output(),tfl_template_to_spec());NULLnone.- style
The study's style the report picks (
"compact": a set ofdefaults.yml'sstyles:, its look – page and table details);NULL:standard.
Value
tfl_r(): a string of class tfl_r; tfl_unset(): an object
of class tfl_unset; the rest: lists of class tfl_call, tfl_item,
tfl_output.
Details
tfl_r(): a string of R code, written as the!rtag (where: !r "p > 0.5"); kept as it is and put into the program unquoted.tfl_unset(): the!unsettag – a value a report sets to nothing, overriding its defaults (writing nothing leaves the default). It is resolved when the defaults are layered; the generators never see one.tfl_call(): a nested call ({fn: rtf_border, args: {top: single}}), for an argument that is itself a constructor's result.tfl_item(): one layer ofcontent:– a function (fn), its arguments by name (args), and where it came from (from:"own","defaults"or"pattern:<name>").tfl_output(): one report:id,kind,label,population,extends,data,codelists,content(a list oftfl_item) andpage.