Skip to contents

Although rtables are represented as a tree data structure when outputting the table to ASCII or HTML, it is useful to map the rtable to an in-between state with the formatted cells in a matrix form.

Usage

# S4 method for listing_df
matrix_form(obj, indent_rownames = FALSE, expand_newlines = TRUE)

Arguments

obj

(ANY)
object to be transformed into a ready-to-render form (a MatrixPrintForm object).

indent_rownames

(flag)
silently ignored, as listings do not have row names nor indenting structure.

expand_newlines

(flag)
this should always be TRUE for listings. We keep it for debugging reasons.

Value

a MatrixPrintForm object.

Examples

lsting <- as_listing(mtcars)
mf <- matrix_form(lsting)