df_to_viewer | R Documentation |
via stargazer and knitr
df_to_viewer(
x,
rownames = TRUE,
summ = F,
kable = TRUE,
by = NULL,
html = FALSE,
colformat = NULL,
sg.style = "ajs",
k.style = "default",
digits = 2,
kable.options = list(),
cells.by.merge = T,
cells.by.indent = T,
...
)
rownames |
Logical, if rownames should be shown. |
summ |
Passed to 'summary' argument of stargazer. |
kable |
logical. If data.frame should be passed to kable. If true, ... will be passed to function kableExtra::kable_styling. Defaults to TRUE. If FALSE, passes df to stargazer. |
by |
The name of variable to group the rows by. Used only when 'kable=TRUE' |
html |
If viewer should be ignored and just html code returned (useful to embed in Rmarkdown outputs |
colformat |
Formats each column using ‘sprintf'. If numeric, applies rounding only, if character, is passed to 'sprintf' directly. Can be named to match x’s column names. If not named, must have the same length as there are columns in x. |
sg.style |
'style' argument of 'stargazer'. |
k.style |
Applies custom kableStyling style, might take two values "default", and "custom". |
kable.options |
A list of arguments passed to 'kable' function. |
cells.by.merge |
The headers created by ‘by' argument can be a single cell spanning all the columns (TRUE) or the subheader can be put in the new line’s first column (FALSE). The latter tables are easier to hande in, e.g. MS Word. |
cells.by.indent |
Logical. Whether 'by' headers should have an indent. |
... |
Other arguments passed to 'stargazer' or 'kableStyling()'. |
df |
data.frame to show. Also works with a list of fitted lm() models. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.