| Title: | Interactive Table of Descriptive Statistics in HTML | 
| Version: | 0.4.0 | 
| Description: | Create an interactive table of descriptive statistics in HTML. This table is typically used for exploratory analysis in a clinical study (referred to as 'Table 1'). | 
| License: | GPL (≥ 3) | 
| Encoding: | UTF-8 | 
| RoxygenNote: | 7.2.3 | 
| Imports: | metalite, reactable, htmltools, r2rtf, jsonlite | 
| Suggests: | knitr, table1, devtools, ggplot2 | 
| VignetteBuilder: | knitr | 
| NeedsCompilation: | no | 
| Packaged: | 2024-04-10 01:15:42 UTC; r220573 | 
| Author: | Yilong Zhang [aut, cre] | 
| Maintainer: | Yilong Zhang <elong0527@gmail.com> | 
| Repository: | CRAN | 
| Date/Publication: | 2024-04-10 02:20:03 UTC | 
metalite.table1: Interactive Table of Descriptive Statistics in HTML
Description
Create an interactive table of descriptive statistics in HTML. This table is typically used for exploratory analysis in a clinical study (referred to as 'Table 1').
Author(s)
Maintainer: Yilong Zhang elong0527@gmail.com
Interactive Table of Descriptive Statistics in HTML
Description
Interactive Table of Descriptive Statistics in HTML
Usage
metalite_table1(
  formula,
  data,
  id,
  var_listing = NULL,
  total = TRUE,
  header = NULL,
  download = "none",
  record_name = NULL,
  ...
)
Arguments
formula | 
 an object of class "formula".  | 
data | 
 a data frame that contain variables described in the   | 
id | 
 a character value to indicate subject/record id variable name in   | 
var_listing | 
 a character vector of additional variables included in the drill down listing.  | 
total | 
 a logical value to display or hide "Total" column.  | 
header | 
 a logical vector with length 1 or same length of the variables in   | 
download | 
 a character value to enable download button. Allowed values include "none", "listing", "table", and 'all'.  | 
record_name | 
 a character value to control section title (e.g. "Subjects", "Records").  | 
... | 
 additional arguments passed to   | 
Value
a shiny.tag.list object that contain a reactable HTML widget for
interactive table of describptive statistics.
Examples
if (interactive()) {
  metalite_table1(~ AGE + SEX | TRT01A, data = r2rtf::r2rtf_adsl, id = "SUBJID")
}
Convert to html
Description
Convert to html
Usage
metalite_table1_to_html(x)
Arguments
x | 
 an output from   | 
Value
HTML string of reactable HTML widget for
interactive table of describptive statistics.
Convert metalite_table1 to an RTF file
Description
Convert metalite_table1 to an RTF file
Usage
metalite_table1_to_rtf(
  x,
  file,
  title = "Baseline Characteristics",
  col_rel_width = NULL
)
Arguments
x | 
 Output of   | 
file | 
 A character string naming a file to save rtf file.  | 
title | 
 Title in a character string.  | 
col_rel_width | 
 Column relative width in a vector e.g. c(2,1,1) refers to 2:1:1. Default is NULL for equal column width.  | 
Value
a string of the RTF file path
Convert reactable to a data frame
Description
Convert reactable to a data frame
Usage
reactable_to_df(x)
Arguments
x | 
 A   | 
Value
A data frame