diff --git a/src/MEDS_DEV/datasets/MIMIC-IV/predicates.yaml b/src/MEDS_DEV/datasets/MIMIC-IV/predicates.yaml index cc81b04..d12700f 100644 --- a/src/MEDS_DEV/datasets/MIMIC-IV/predicates.yaml +++ b/src/MEDS_DEV/datasets/MIMIC-IV/predicates.yaml @@ -14,5 +14,154 @@ predicates: icu_discharge: code: { regex: "^ICU_DISCHARGE//.*" } + birth: + code: MEDS_BIRTH death: code: MEDS_DEATH + + creatinine_1: + code: LAB//50912//mg/dL + creatinine_2: + code: LAB//52546//mg/dL + abnormally_high_creatinine_1: + code: LAB//50912//mg/dL + value_min: 1.3 # mg/dL + value_min_inclusive: False + value_max: null + abnormally_high_creatinine_2: + code: LAB//52546//mg/dL + value_min: 1.3 # mg/dL + value_min_inclusive: False + value_max: null + creatinine: + expr: or(creatinine_1, creatinine_2) + abnormally_high_creatinine: + expr: or(abnormally_high_creatinine_1, abnormally_high_creatinine_2) + + sodium_1: + code: LAB//220645//mEq/L + sodium_2: + code: LAB//50983//mEq/L + sodium_3: + code: LAB//52623//mEq/L + abnormally_low_sodium_1: + code: LAB//220645//mEq/L + value_min: null + value_max: 135 # mEq/L + value_max_inclusive: False + abnormally_low_sodium_2: + code: LAB//50983//mEq/L + value_min: null + value_max: 135 # mEq/L + value_max_inclusive: False + abnormally_low_sodium_3: + code: LAB//52623//mEq/L + value_min: null + value_max: 135 # mEq/L + value_max_inclusive: False + sodium: + expr: or(sodium_1, sodium_2, sodium_3) + abnormally_low_sodium: + expr: or(abnormally_low_sodium_1, abnormally_low_sodium_2, abnormally_low_sodium_3) + + bicarbonate_1: + code: LAB//227443//mEq/L + bicarbonate_2: + code: LAB//50882//mEq/L + abnormally_low_bicarbonate_1: + code: LAB//227443//mEq/L + value_min: null + value_max: 22 # mEq/L + value_max_inclusive: False + abnormally_low_bicarbonate_2: + code: LAB//50882//mEq/L + value_min: null + value_max: 22 # mEq/L + value_max_inclusive: False + bicarbonate: + expr: or(bicarbonate_1, bicarbonate_2) + abnormally_low_bicarbonate: + expr: or(abnormally_low_bicarbonate_1, abnormally_low_bicarbonate_2) + + hemoglobin_1: + code: LAB//220228//g/dl + hemoglobin_2: + code: LAB//50811//g/dL + abnormal_hemoglobin_1: + code: LAB//220228//g/dl + value_min: null + value_max: 13 # g/dL + value_max_inclusive: False + abnormal_hemoglobin_2: + code: LAB//50811//g/dL + value_min: null + value_max: 13 # g/dL + value_max_inclusive: False + hemoglobin: + expr: or(hemoglobin_1, hemoglobin_2) + abnormal_hemoglobin: + expr: or(abnormal_hemoglobin_1, abnormal_hemoglobin_2) + + wbc_1: + code: LAB//220546//K/uL + wbc_2: + code: LAB//51300//K/uL + abnormally_high_wbc_1: + code: LAB//220546//K/uL + value_min: 11 # K/uL + value_min_inclusive: False + value_max: null + abnormally_high_wbc_2: + code: LAB//51300//K/uL + value_min: 11 # K/uL + value_min_inclusive: False + value_max: null + wbc: + expr: or(wbc_1, wbc_2) + abnormally_high_wbc: + expr: or(abnormally_high_wbc_1, abnormally_high_wbc_2) + + platelets_1: + code: LAB//227457//K/uL + platelets_2: + code: LAB//51265//K/uL + abnormally_low_platelets_1: + code: LAB//227457//K/uL + value_min: null + value_max: 150 # K/uL + value_max_inclusive: False + abnormally_low_platelets_2: + code: LAB//51265//K/uL + value_min: null + value_max: 150 # K/uL + value_max_inclusive: False + platelets: + expr: or(platelets_1, platelets_2) + abnormally_low_platelets: + expr: or(abnormally_low_platelets_1, abnormally_low_platelets_2) + + map_1: + code: LAB//220052//mmHg + map_2: + code: LAB//220181//mmHg + map_3: + code: LAB//225312//mmHg + abnormally_low_map_1: + code: LAB//220052//mmHg + value_min: null + value_max: 65 # mmHg + value_max_inclusive: False + abnormally_low_map_2: + code: LAB//220181//mmHg + value_min: null + value_max: 65 # mmHg + value_max_inclusive: False + abnormally_low_map_3: + code: LAB//225312//mmHg + value_min: null + value_max: 65 # mmHg + value_max_inclusive: False + map: + expr: or(map_1, map_2, map_3) + abnormally_low_map: + expr: or(abnormally_low_map_1, abnormally_low_map_2, abnormally_low_map_3)