Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Table 4.6 mistake ? #145

Open
tguiot opened this issue Oct 4, 2022 · 1 comment
Open

Table 4.6 mistake ? #145

tguiot opened this issue Oct 4, 2022 · 1 comment

Comments

@tguiot
Copy link

tguiot commented Oct 4, 2022

Hi

OHDSI newbie here. I am reading the doc and think there might be a mistake in table 4.6:

Column name Value Explanation
ADMITTED_FROM_ CONCEPT_ID 0 If known, this is contains a Concept representing where the patient was admitted from. This concept should have the domain "Visit". For example, if the patient were admitted to the hospital from home it would contain 8536 ("Home").
ADMITTED_FROM_ SOURCE_CONCEPT_ID NULL This is the value from the source that represents where the patient was admitted from. Using the above example, this would be "home".

Unless I got everything wrong, shouldn't it be ADMITTED_FROM_ SOURCE_VALUE instead of CONCEPT_ID ?

Also I spotted this possible mistake because the example mixes "NULL" and "0" for fields that are supposed to be ID's. Is there a reason why the value given in the examples is sometimes NULL and sometimes 0 ?

thanks
Thomas

@cgreich
Copy link
Contributor

cgreich commented Oct 4, 2022

@tguiot:

Yeah. It's confusing. All fields indicating what the record actually is about (starting with admitted_, drug_, condition_, etc.) exist in three incarnation:

  • _concept_id - the standard concept representing the content of the record. This is the important one
  • source_concept_id - the concept used at the source, as an OMOP vocabulary concept
  • source_value - the original code as indicated in the source

The latter two are there only for debugging and if the standard for some reason does not work. They should not be used much at all.

The 0/NULL question: If the record does not make sense with a NULL you have to put in 0. So, the _concept_id fields, as above, indicate the content of the record. If it is NULL it makes the record useless. The 0 indicates that there was an event or entity, but it content cannot be represented by a standard concept. the _source_concept_id or _source_value might still have some information. But even if they don't: You want to keep the record for reasons of calculations where you need a denominator. All other fields should be 0 if there is a value but the data don't know it. If however the field is not useful (e.g. a Measurement without a unit) the field should be set to NULL.

Generally, the CDM documentation is the place where you get the official instructions. The cookbook doesn't go into details like that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants