TableBlock | R Documentation |
TableBlock
Specialized FileBlock
for managing table content in reports.
It's designed to handle various table formats, converting them into a consistent,
document-ready format (e.g., flextable
) for inclusion in reports.
teal.reporter::ContentBlock
-> teal.reporter::FileBlock
-> TableBlock
new()
Initialize a TableBlock
object.
TableBlock$new(table)
table
(data.frame
or rtables
or TableTree
or ElementaryTable
or listing_df
) a table assigned to
this TableBlock
Object of class TableBlock
, invisibly.
set_content()
Sets content of this TableBlock
.
TableBlock$set_content(content)
content
(data.frame
or rtables
or TableTree
or ElementaryTable
or listing_df
)
a table assigned to this TableBlock
Raises error if argument is not a table-like object.
self
, invisibly.
TableBlock <- getFromNamespace("TableBlock", "teal.reporter") block <- TableBlock$new() block$set_content(iris)
clone()
The objects of this class are cloneable with this method.
TableBlock$clone(deep = FALSE)
deep
Whether to make a deep clone.
## ------------------------------------------------
## Method `TableBlock$set_content`
## ------------------------------------------------
TableBlock <- getFromNamespace("TableBlock", "teal.reporter")
block <- TableBlock$new()
block$set_content(iris)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.