View source: R/tableCohortTiming.R
tableCohortTiming | R Documentation |
tableCohortTiming(
result,
timeScale = "days",
uniqueCombinations = TRUE,
type = "gt",
header = visOmopResults::strataColumns(result),
groupColumn = NULL,
hide = "variable_level"
)
result |
A summarised_result object. Output of summariseCohortTiming(). |
timeScale |
Time scale to plot results. Can be days or years. |
uniqueCombinations |
Whether to restrict to unique reference and comparator comparisons. |
type |
Type of table. Check supported types with
|
header |
Columns to use as header. See options with
|
groupColumn |
Columns to group by. See options with
|
hide |
Columns to hide from the visualisation. See options with
|
A formatted table of the summariseCohortTiming result.
## Not run:
library(CohortCharacteristics)
library(duckdb)
library(CDMConnector)
library(DrugUtilisation)
con <- dbConnect(duckdb(), eunomiaDir())
cdm <- cdmFromCon(con, cdmSchem = "main", writeSchema = "main")
cdm <- generateIngredientCohortSet(
cdm = cdm,
name = "my_cohort",
ingredient = c("acetaminophen", "morphine", "warfarin")
)
timings <- summariseCohortTiming(cdm$my_cohort)
plotCohortTiming(
timings,
timeScale = "years",
facet = c("cdm_name", "cohort_name_reference"),
colour = c("cohort_name_comparator")
)
cdmDisconnect(cdm)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.