Reformat cohort definition tables
Source:R/ssc_process_subfuncs_pcornet.R
compare_cohort_def_pcnt.RdReformat cohort definition tables
Usage
compare_cohort_def_pcnt(
base_cohort,
alt_cohorts,
multi_or_single_site,
person_tbl = cdm_tbl("demographic"),
visit_tbl = cdm_tbl("encounter"),
provider_tbl = NULL,
care_site_tbl = NULL,
demographic_mappings = sensitivityselectioncriteria::ssc_pcornet_demographics,
specialty_concepts = NULL,
outcome_concepts = NULL,
domain_defs = sensitivityselectioncriteria::ssc_domain_file,
domain_select = sensitivityselectioncriteria::ssc_domain_file %>% distinct(domain)
%>% pull()
)Arguments
- base_cohort
table with the base cohort & inclusion criteria; must include site, person_id, start_date, end_date
- alt_cohorts
list of each table with an alternative inclusion criteria definition applied to the base_cohort
- multi_or_single_site
direction to determine what kind of check to run string that is either
multiorsingle- person_tbl
the CDM table that contains patient information
- visit_tbl
the CDM table that contains visit/encounter information
- provider_tbl
the CDM table with provider & provider specialty information only used if
specialty_conceptsare provided if provider_tbl & care_site_tbl are both not null, provider specialty is prioritized- care_site_tbl
the CDM table with care site / facility & care site / facility specialty information only used if
specialty_conceptsare provided if provider_tbl & care_site_tbl are both not null, provider specialty is prioritized- demographic_mappings
table defining how demographic elements should be defined if NULL, the default demographic mappings for the CDM will be used (
ssc_pcornet_demographics) otherwise, the user provided table will be used- specialty_concepts
a concept set with provider specialty concepts of interest to be used to identify specialty visits
- outcome_concepts
a concept set with the following columns:
concept_id|concept_code|concept_name|vocabulary_id|variable|domain- domain_defs
a table with domain definitions with the following columns: domain, domain_tbl, concept_field, date_field, filter_logic
- domain_select
a vector of domain names that should be used in the computation of facts per domain per year of follow up