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)

Arguments

obj

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

indent_rownames

logical(1). Silently ignored, as listings do not have row names nor indenting structure.

Value

a MatrixPrintForm object

Details

The strings in the return object are defined as follows: row labels are those determined by summarize_rows and cell values are determined using get_formatted_cells. (Column labels are calculated using a non-exported internal function.

Examples


lsting <- as_listing(mtcars)
#> sorting incoming data by key columns
mf <- matrix_form(lsting)