tableDrugRestart {DrugUtilisation} | R Documentation |
Format a drug_restart object into a visual table.
Description
Format a drug_restart object into a visual table.
Usage
tableDrugRestart(
result,
header = c("cdm_name", "cohort_name"),
groupColumn = "variable_name",
type = "gt",
hide = c("censor_date", "restrict_to_first_discontinuation", "follow_up_days",
"cohort_table_name", "incident", "switch_cohort_table"),
.options = list()
)
Arguments
result |
A summarised_result object. |
header |
Columns to use as header. See options with
|
groupColumn |
Columns to group by. See options with
|
type |
Type of table. Check supported types with
|
hide |
Columns to hide from the visualisation. See options with
|
.options |
A named list with additional formatting options.
|
Value
A table with a formatted version of summariseDrugRestart() results.
Examples
library(DrugUtilisation)
cdm <- mockDrugUtilisation()
conceptlist <- list(acetaminophen = 1125360, metformin = c(1503297, 1503327))
cdm <- generateDrugUtilisationCohortSet(cdm = cdm,
name = "switch_cohort",
conceptSet = conceptlist)
result <- cdm$cohort1 |>
summariseDrugRestart(switchCohortTable = "switch_cohort")
tableDrugRestart(result)
[Package DrugUtilisation version 1.0.4 Index]