format_xtable: Format Entries in an 'xtable' into Character Strings

Description Usage Arguments Details Value

View source: R/format_xtable.bare.R

Description

Format entries in an xtable object into character strings. (This is essentially a format method for xtable objects.) This is an internal function not intended to be called by package users.

Usage

1
format_xtable(x, row.names=TRUE, na="NA", mathExponents=TRUE, ...)

Arguments

x

An xtable object.

row.names

Logical scalar. If FALSE, the row names of x are not included in the returned formatted table.

na

String to be used to represent missing values in x. The default value is the empty string "".

mathExponents

Logical scalar. If TRUE, then numerical values in x that are formatted into scientific notation (i.e., strings like "3.14e-02", specified by values of e or E in the display attribute of x) will be plotted in math style, with the power of 10 shown as a superscript.

...

Additional named arguments passed to formatC, when converting values in x to character strings. They must not include digits or format, which are specified within x itself.

Details

This is mostly code extracted from print.xtable in version 1.8-4 of the xtable package by David B. Dahl et al.

Value

A character matrix with one row per row in x (not counting column names), and one column per column in x (including a column of row names, if row.names is TRUE).


tablesgg documentation built on June 3, 2021, 1:06 a.m.