Description Usage Arguments Details See Also Examples
Markdown is emitted to the console, and optionally to an external file.
1 2 | print_table1(summary_table, title = "**Table 1**", caption = "",
output_file)
|
summary_table |
The qwraps2::summary_table object to print. |
title |
The title for the table. |
caption |
The caption for the table. |
output_file |
(optional) The file to which to write the markdown. |
This function takes as input a qwraps2::summary_table()
object'. See the
documentation and vignettes of that package to learn how to use qwraps2.
qwraps2::summary_table()
, browseVignettes('qwraps2')
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | require(qwraps2)
mtcars_summaries <-
list('Miles Per Gallon' =
list('min' = ~ min(mpg),
'mean' = ~ mean(mpg),
'mean ± sd' = ~ qwraps2::mean_sd(mpg),
'max' = ~ max(mpg)),
'Weight' =
list('median' = ~ median(wt)),
'Cylinders' =
list('4 cyl: n (%)' = ~ qwraps2::n_perc0(cyl == 4),
'6 cyl: n (%)' = ~ qwraps2::n_perc0(cyl == 6),
'8 cyl: n (%)' = ~ qwraps2::n_perc0(cyl == 8)))
print_table1(summary_table = qwraps2::summary_table(mtcars, mtcars_summaries),
title = '**mtcars summary table**',
caption = 'example using mtcars')
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.