See core documentation in formatters::formatters-package for descriptions of these functions.
Usage
# S3 method for class 'listing_df'
print(
  x,
  widths = NULL,
  tf_wrap = FALSE,
  max_width = NULL,
  fontspec = NULL,
  col_gap = 3L,
  round_type = c("iec", "sas"),
  ...
)
# S4 method for class 'listing_df'
toString(
  x,
  widths = NULL,
  fontspec = NULL,
  col_gap = 3L,
  round_type = c("iec", "sas"),
  ...
)
# S4 method for class 'listing_df'
x[i, j, drop = FALSE]
# S4 method for class 'listing_df'
main_title(obj)
# S4 method for class 'listing_df'
subtitles(obj)
# S4 method for class 'listing_df'
main_footer(obj)
# S4 method for class 'listing_df'
prov_footer(obj)
# S4 method for class 'listing_df'
main_title(obj) <- value
# S4 method for class 'listing_df'
subtitles(obj) <- value
# S4 method for class 'listing_df'
main_footer(obj) <- value
# S4 method for class 'listing_df'
prov_footer(obj) <- value
# S4 method for class 'listing_df'
num_rep_cols(obj)Arguments
- x
- ( - listing_df)
 the listing.
- widths
- ( - numericor- NULL)
 Proposed widths for the columns of- x. The expected length of this numeric vector can be retrieved with- ncol(x) + 1as the column of row names must also be considered.
- tf_wrap
- ( - flag)
 whether the text for title, subtitles, and footnotes should be wrapped.
- max_width
- ( - integer(1),- stringor- NULL)
 width that title and footer (including footnotes) materials should be word-wrapped to. If- NULL, it is set to the current print width of the session (- getOption("width")). If set to- "auto", the width of the table (plus any table inset) is used. Parameter is ignored if- tf_wrap = FALSE.
- fontspec
- ( - font_spec)
 a font_spec object specifying the font information to use for calculating string widths and heights, as returned by- font_spec().
- col_gap
- ( - numeric(1))
 space (in characters) between columns.
- round_type
- ( - "iec"or- "sas")
 the type of rounding to perform. iec, the default, peforms rounding compliant with IEC 60559 (see details), while sas performs nearest-value rounding consistent with rounding within SAS.
- ...
- additional parameters passed to - formatters::toString().
- i
- ( - any)
 object passed to base- [methods.
- j
- ( - any)
 object passed to base- [methods.
- drop
- relevant for matrices and arrays. If - TRUEthe result is coerced to the lowest possible dimension (see the examples). This only works for extracting elements, not for the replacement. See- dropfor further details.
- obj
- ( - listing_df)
 the listing.
- value
- typically an array-like R object of a similar class as - x.
Value
- Accessor methods return the value of the aspect of - obj.
- Setter methods return - objwith the relevant element of the listing updated.
Examples
lsting <- as_listing(mtcars)
main_title(lsting) <- "Hi there"
main_title(lsting)
#> [1] "Hi there"