- In OMOP what are the difference between the following 2 tables?
- If I want to ETL Allergy data, which table should I use?
We are working on an ETL that has allergy data. We found that we could map
over 80% of the allergy values to OMOP concepts. The domain id of the
majority of these is Condition. Example: concept id 4302207 (allergy to
grass pollen) has the domain id Condition. For the allergies we can map we
are using the domain id to determine the target table. Those that cannot
be mapped we are putting into the Observation table, but we feel that the
decision is arbitrary and you can make an argument for putting unmapped
values in the condition table.
Just to be clear - for those concepts you can map - you would enter it into the condition_occurrence table where condition_concept_id = 4302207. What would you enter into the condition_start_date if the information is not provided? The date of service/encounter?
The start date column is NOT NULL, so you do need a date. And the only alternative is the service/encounter date.
If the allergy information is from patient history or patient reported the answer of where to put the data is more nuanced because patient history information can go into either Observation or Condition table. You have to think about how analysis will be done using the database. For example, the OMOP Condition Occurrence table is often used to answer questions like, person took drug X and had reaction Y. Or the other way around person has condition X and is treated with medication Y. To do these analysis requires that the condition and drug exposure start dates reflect the state of the person at the time recorded.
If your allergy data is historical or patient reported you can put it in the Observation table, which is where things get put when you don’t want to loose the information, but are not sure what to do with it, or you can still put it in the Condition Occurrence table, but make sure to set the Condition Type concept to ‘EHR problem list entry’ or ‘Patient Self-Reported Condition’. These Condition Type values should be enough to alert researchers to the fact that the condition start date may not indicate when the Allergy diagnosis was made.
I suggest waiting to see if there are some other opinions. Part of answering these questions is to have your answer corrected.
Nice posting. We should clean this up. Here it is:
Allergies are always historical facts. Something the patient learned after the fact. An ongoing allergy is a Condition, but you wouldn’t record the source, even if you knew it. You would record the local response (eczema, allergic rhinitis) or the systemic reaction (laryngeal edema, anaphylactic shock).
The typical allergy report should be an Observation, with the allergen, if known, recorded in value_as_concept_id. But that’s not how it is mapped right now. Instead, the allergic “conditions” are now mapped to SNOMED Condition concepts or to 43530807 “Allergic disposition” if the allergen is not listed. We need to bring this up with the CDM WG. @Dymshyts has also looked into this before.
How would you suggest handling a substance allergy?
If the allergen is recorded in the observation.value_as_concept_id - for example oxycontin (19076182) then the fact it is a drug concept it is assumed to be an allergy? Or would you add additional information in the observation_type_concept_id and qualifier_concept_id to make it clear the observation entry?
You also need to record in the observation_concept_id 4166257 (“Allergic reaction to drug”). Only flaw in this picture: This is a Condition concept, not an observation concept. And in the Condition table you cannot have value_as_concept_id. We need to find a good solution for this problem. But that’s what I would do in your situation right now.
The observation_type_concept_id depicts the origin of the information. It doesn’t qualify the meaning. The qualifier_concept_id is for qualifiers like right or left, so it is not the right field either.
just to be clear
43530807 “Allergic disposition” and 4166257 (“Allergic reaction to drug”) are two different things.
and then you want to map for example
Pindolol allergy - Maps to - “Allergic disposition”;
Correct. And yes about the difference between disposition and actual reaction. But here lies the problem: If it is a reaction we need to treat it as a Condition, and then we don’t have a value_as_concept_id field.
“Dermatitis”, “Angioedema” or something like that should be treated as a condition,
but “Allergic reaction to drug” is an observation.
Running into this same issue. We have distinct events of patients experiencing adverse reactions to drugs.
Just to be clear, was the resolution to ignore the (condition) domain of ‘Allergic reaction to drug’ (4166257) and use it as the observation_concept_id in the observation table?
There are similar concepts within the observation domain regarded as events but they are not standard and end up getting mapped to the aforementioned condition.
concept_id concept_name domain_id vocabulary_id concept_class_id 40421705 Adverse reaction to other drugs and medicines Observation SNOMED Event
Alternatively, drug interactions are regarded as clinical observations. This seems the most logical to me.
concept_id concept_name domain_id vocabulary_id concept_class_id 40488461 Adverse drug interaction Observation SNOMED Clinical Finding
so what’s the actual problem to use “441207 Adverse reaction to drug” (domain_id = ‘Condition’) and put it in Condition_occurrence table?
“Adverse reaction to drug” is a kind of medical condition eventually - “Blood pressure decrease”, “Kidney failure”, “Angioedema”, etc.
If we use the condition table instead of the observation table we would lose the ability to use value_as_concept_id to specify the drug which caused the reaction.
There are conditions in the vocabularies that specify the drug (e.g 433658,Penicillin adverse reaction) though its not clear how inclusive they are or how you could map to these concepts without needing to do it manually.
As @rtmill says, and we already discussed.
Both “Adverse reaction to drug” and “Allergic disposition” are Observations. And “Adverse reaction to drug” is a current event, but not a Condition, because it denotes a relationship of some reaction (not given) to a drug. Hence an Observation. Makes sense?
Can you make them both Observations, and we are good?
Ok. Got it. Will change in the next release.
By the way, here is another issue,
@rtmill, have you had a use cases when you need to put there something like “Adverse reaction to antibiotics”, i.e. you need to represent the group of drugs?
@Christian_Reich, if we want to make this possible, we need to make ATC standard. What do you think?
No, we haven’t had any of those use cases. The reactions are qualified with an NDC code and description. That said, there are also instances of adverse reactions to foods without code identifiers.
I believe if there were an ‘Adverse reaction to substance’ concept in the Observation domain it would resolve my issues, though having both ‘Adverse reaction to drug’ and ‘Adverse reaction to food’ would be helpful.
It’s odd to me that SNOMED would classify both the event of an allergic reaction (‘Adverse Drug Reaction’) and the allergy itself (‘Drug Allergy’) as disorders
Yep, that’s strange,
especially taking into account that children of (‘Adverse Drug Reaction’) and (‘Drug Allergy’) are the allergies caused by different drugs (looks like events), not a different types of Allergy (anaphylactic shock, urticaria, etc. - that might be classified as a disease normally).
So we’ll change it on our side making them Observations