A function to print the table spec.
The print function will print the table spec in summary
form. To view all parameters, set the verbose
parameter to TRUE.
# S3 method for table_spec print(x, ..., verbose = FALSE)
x | The table spec. |
---|---|
... | Additional parameters to pass to the underlying print function. |
verbose | Whether to print in verbose form, which is similar to a list. Default is FALSE, which prints in summary form. |
The table spec, invisibly.
create_table
function to create a table specification.
Other table:
column_defaults()
,
create_table()
,
define()
,
spanning_header()
,
stub()
library(magrittr) # Create Table tbl <- create_table(mtcars) %>% define(mpg, label = "Miles Per Gallon", width = .5) %>% define(cyl, label = "Cylinders") %>% titles("Table 6.4", "MTCARS Sample Table") %>% footnotes("* Motor Trend, 1974") tbl # A table specification: # - data: data.frame 'mtcars' 32 rows 11 cols # - show_cols: all # - use_attributes: all # - title 1: 'Table 6.4' # - title 2: 'MTCARS Sample Table' # - footnote 1: '* Motor Trend, 1974' # - define: mpg 'Miles Per Gallon' width=0.5 # - define: cyl 'Cylinders'