tableLargeScaleCharacteristics {CohortCharacteristics} | R Documentation |
Format a summarised_large_scale_characteristics object into a visual table.
Description
'r lifecycle::badge("experimental")'
Usage
tableLargeScaleCharacteristics(
result,
type = "gt",
formatEstimateName = c(`N (%)` = "<count> (<percentage>%)"),
splitStrata = TRUE,
header = c("cdm name", "cohort name", "strata", "window name"),
topConcepts = NULL
)
Arguments
result |
A summarised_large_scale_characteristics object. |
type |
Output type ("gt" or "flextable"). |
formatEstimateName |
Named list of estimate name's to join, sorted by computation order. Indicate estimate_name's between <...>. |
splitStrata |
Whether to split strata_group and strata_level to multiple columns. |
header |
Specify the headers of the table. |
topConcepts |
Number of concepts to restrict the table. |
Value
A formatted table.
Examples
## Not run:
library(DBI)
library(duckdb)
library(CDMConnector)
con <- dbConnect(duckdb(), eunomia_dir())
cdm <- cdmFromCon(con = con, cdmSchema = "main", writeSchema = "main")
cdm <- generateConceptCohortSet(
cdm = cdm,
conceptSet = list("viral_pharyngitis" = 4112343),
name = "my_cohort"
)
result <- summariseLargeScaleCharacteristics(
cohort = cdm$my_cohort,
eventInWindow = "condition_occurrence",
episodeInWindow = "drug_exposure"
)
tableLargeScaleCharacteristics(result)
## End(Not run)
[Package CohortCharacteristics version 0.2.2 Index]