umop.v1.omop.cohort package¶
Submodules¶
umop.v1.omop.cohort.complete_cohort module¶
OMOP Complete Cohort Documentation.
- umop.v1.omop.cohort.complete_cohort.get_cohort(engine, include_icd10s=[], exclude_icd10s=[], start_date=None, end_date=None, age_cutoff=None)¶
This method returns the cohort based on inclusion and exclusion ICD10s. In addition, start_date, end_date and age_cutoff optional arguments can be provided to further limit the cohort.
>>> from umop.v1.omop.cohort.complete_cohort import get_cohort Arguments: ========== include_icd10s = ['U07.1', 'U07.0'] # For example, Strong COVID ICD10s exclude_icd10s = ['O70.0'] # For example, Perineum in Pregnancy ICD10 start_date = "2020-01-01" # Date Format "YYYY-MM-DD" end_date = "2020-05-31" # Date Format "YYYY-MM-DD" age_cutoff = 18 # Limits cohort to 18 years of age or more Returns: ======== "PERSON_ID", "ICD10", "VISIT_OCCURRENCE_ID", "CONDITION_CONCEPT_ID", "PRIMARY_DIAGNOSIS_YN", "VISIT_TYPE", "VISIT_START_DATE", "VISIT_END_DATE", "PROVIDER_ID"
umop.v1.omop.cohort.demographics module¶
OMOP Cohort’s Demographics Documentation.
Given a list of patients ids, returns demographics information for those patients.
- umop.v1.omop.cohort.demographics.get_demographics(engine, pat_list=[])¶
Example:
This method can be used as follows:
>>> from umop.v1.omop.cohort.demographics import get_demographics Given a list of patient ids, it will return PERSON_ID, DOB (random date-shifted), SEX, RACE, ETHNICITY, CITY, STATE, and ZIP.