Skip to content

Commit 4c8f054

Browse files
author
Clair Blacketer
committed
Fix to CDM v6.0 to add back cohort table
1 parent 5927b49 commit 4c8f054

4 files changed

Lines changed: 154 additions & 9 deletions

File tree

docs/cdm60.html

Lines changed: 147 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212

1313

14-
<title>cdm60.utf8</title>
14+
<title>OMOP CDM v6.0</title>
1515

1616
<script src="site_libs/header-attrs-2.6/header-attrs.js"></script>
1717
<script src="site_libs/jquery-1.11.3/jquery.min.js"></script>
@@ -518,12 +518,11 @@
518518

519519

520520

521+
<h1 class="title toc-ignore"><strong>OMOP CDM v6.0</strong></h1>
521522

522523
</div>
523524

524525

525-
<div id="omop-cdm-v6.0" class="section level1">
526-
<h1><strong>OMOP CDM v6.0</strong></h1>
527526
<div id="note-about-cdm-v6.0" class="section level2">
528527
<h2>NOTE ABOUT CDM v6.0</h2>
529528
<p>Please be aware that v6.0 of the OMOP CDM is <strong>not</strong> fully supported by the OHDSI suite of tools and methods. The major difference in CDM v5.3 and CDM v6.0 involves switching the *_datetime fields to mandatory rather than optional. This switch radically changes the assumptions related to exposure and outcome timing. Rather than move forward with v6.0, CDM v5.4 was designed with additions to the model that have been requested by the community while retaining the date structure of medical events in v5.3. Please see our the specifications for <a href="http://ohdsi.github.io/CommonDataModel/cdm54.html">CDM v5.4</a> and detailed <a href="http://ohdsi.github.io/CommonDataModel/cdm54Changes.html">changes from CDM v5.3</a>. <strong>For new collaborators to OHDSI, please transform your data to <a href="https://github.com/OHDSI/CommonDataModel/releases/tag/v5.4">CDM v5.4</a> until such time that the v6 series of the CDM is ready for mainstream use.</strong></p>
@@ -13204,6 +13203,148 @@ <h3 class="tabset tabset-pills">DRUG_STRENGTH</h3>
1320413203
</tbody>
1320513204
</table>
1320613205
</div>
13206+
<div id="cohort" class="section level3 tabset tabset-pills">
13207+
<h3 class="tabset tabset-pills">COHORT</h3>
13208+
<p><strong>Table Description</strong></p>
13209+
<p>The COHORT table contains records of subjects that satisfy a given set of criteria for a duration of time. The definition of the cohort is contained within the COHORT_DEFINITION table. It is listed as part of the RESULTS schema because it is a table that users of the database as well as tools such as ATLAS need to be able to write to. The CDM and Vocabulary tables are all read-only so it is suggested that the COHORT and COHORT_DEFINTION tables are kept in a separate schema to alleviate confusion.</p>
13210+
<p><strong>ETL Conventions</strong></p>
13211+
<p>Cohorts typically include patients diagnosed with a specific condition, patients exposed to a particular drug, but can also be Providers who have performed a specific Procedure. Cohort records must have a Start Date and an End Date, but the End Date may be set to Start Date or could have an applied censor date using the Observation Period Start Date. Cohort records must contain a Subject Id, which can refer to the Person, Provider, Visit record or Care Site though they are most often Person Ids. The Cohort Definition will define the type of subject through the subject concept id. A subject can belong (or not belong) to a cohort at any moment in time. A subject can only have one record in the cohort table for any moment of time, i.e. it is not possible for a person to contain multiple records indicating cohort membership that are overlapping in time</p>
13212+
<table class="table table-condensed table-hover" style="font-size: 13px; margin-left: auto; margin-right: auto;">
13213+
<thead>
13214+
<tr>
13215+
<th style="text-align:left;">
13216+
CDM Field
13217+
</th>
13218+
<th style="text-align:left;width: 3in; ">
13219+
User Guide
13220+
</th>
13221+
<th style="text-align:left;width: 4in; ">
13222+
ETL Conventions
13223+
</th>
13224+
<th style="text-align:left;width: 1in; ">
13225+
Datatype
13226+
</th>
13227+
<th style="text-align:left;width: 1in; ">
13228+
Required
13229+
</th>
13230+
<th style="text-align:left;width: 1in; ">
13231+
Primary Key
13232+
</th>
13233+
<th style="text-align:left;width: 1in; ">
13234+
Foreign Key
13235+
</th>
13236+
<th style="text-align:left;width: 1in; ">
13237+
FK Table
13238+
</th>
13239+
<th style="text-align:left;width: 1in; ">
13240+
FK Domain
13241+
</th>
13242+
</tr>
13243+
</thead>
13244+
<tbody>
13245+
<tr>
13246+
<td style="text-align:left;font-weight: bold;">
13247+
cohort_definition_id
13248+
</td>
13249+
<td style="text-align:left;width: 3in; ">
13250+
</td>
13251+
<td style="text-align:left;width: 4in; ">
13252+
</td>
13253+
<td style="text-align:left;width: 1in; ">
13254+
integer
13255+
</td>
13256+
<td style="text-align:left;width: 1in; ">
13257+
Yes
13258+
</td>
13259+
<td style="text-align:left;width: 1in; ">
13260+
No
13261+
</td>
13262+
<td style="text-align:left;width: 1in; ">
13263+
No
13264+
</td>
13265+
<td style="text-align:left;width: 1in; ">
13266+
</td>
13267+
<td style="text-align:left;width: 1in; ">
13268+
</td>
13269+
</tr>
13270+
<tr>
13271+
<td style="text-align:left;font-weight: bold;">
13272+
subject_id
13273+
</td>
13274+
<td style="text-align:left;width: 3in; ">
13275+
</td>
13276+
<td style="text-align:left;width: 4in; ">
13277+
</td>
13278+
<td style="text-align:left;width: 1in; ">
13279+
integer
13280+
</td>
13281+
<td style="text-align:left;width: 1in; ">
13282+
Yes
13283+
</td>
13284+
<td style="text-align:left;width: 1in; ">
13285+
No
13286+
</td>
13287+
<td style="text-align:left;width: 1in; ">
13288+
No
13289+
</td>
13290+
<td style="text-align:left;width: 1in; ">
13291+
</td>
13292+
<td style="text-align:left;width: 1in; ">
13293+
</td>
13294+
</tr>
13295+
<tr>
13296+
<td style="text-align:left;font-weight: bold;">
13297+
cohort_start_date
13298+
</td>
13299+
<td style="text-align:left;width: 3in; ">
13300+
</td>
13301+
<td style="text-align:left;width: 4in; ">
13302+
</td>
13303+
<td style="text-align:left;width: 1in; ">
13304+
date
13305+
</td>
13306+
<td style="text-align:left;width: 1in; ">
13307+
Yes
13308+
</td>
13309+
<td style="text-align:left;width: 1in; ">
13310+
No
13311+
</td>
13312+
<td style="text-align:left;width: 1in; ">
13313+
No
13314+
</td>
13315+
<td style="text-align:left;width: 1in; ">
13316+
</td>
13317+
<td style="text-align:left;width: 1in; ">
13318+
</td>
13319+
</tr>
13320+
<tr>
13321+
<td style="text-align:left;font-weight: bold;">
13322+
cohort_end_date
13323+
</td>
13324+
<td style="text-align:left;width: 3in; ">
13325+
</td>
13326+
<td style="text-align:left;width: 4in; ">
13327+
</td>
13328+
<td style="text-align:left;width: 1in; ">
13329+
date
13330+
</td>
13331+
<td style="text-align:left;width: 1in; ">
13332+
Yes
13333+
</td>
13334+
<td style="text-align:left;width: 1in; ">
13335+
No
13336+
</td>
13337+
<td style="text-align:left;width: 1in; ">
13338+
No
13339+
</td>
13340+
<td style="text-align:left;width: 1in; ">
13341+
</td>
13342+
<td style="text-align:left;width: 1in; ">
13343+
</td>
13344+
</tr>
13345+
</tbody>
13346+
</table>
13347+
</div>
1320713348
<div id="cohort_definition" class="section level3 tabset tabset-pills">
1320813349
<h3 class="tabset tabset-pills">COHORT_DEFINITION</h3>
1320913350
<p><strong>Table Description</strong></p>
@@ -13251,7 +13392,7 @@ <h3 class="tabset tabset-pills">COHORT_DEFINITION</h3>
1325113392
<td style="text-align:left;width: 4in; ">
1325213393
</td>
1325313394
<td style="text-align:left;width: 1in; ">
13254-
bigint
13395+
integer
1325513396
</td>
1325613397
<td style="text-align:left;width: 1in; ">
1325713398
Yes
@@ -13260,9 +13401,10 @@ <h3 class="tabset tabset-pills">COHORT_DEFINITION</h3>
1326013401
No
1326113402
</td>
1326213403
<td style="text-align:left;width: 1in; ">
13263-
No
13404+
Yes
1326413405
</td>
1326513406
<td style="text-align:left;width: 1in; ">
13407+
COHORT
1326613408
</td>
1326713409
<td style="text-align:left;width: 1in; ">
1326813410
</td>
@@ -13429,7 +13571,6 @@ <h3 class="tabset tabset-pills">COHORT_DEFINITION</h3>
1342913571
</table>
1343013572
</div>
1343113573
</div>
13432-
</div>
1343313574

1343413575

1343513576

inst/csv/OMOP_CDMv6.0_Field_Level.csv

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -534,7 +534,11 @@ recorded. The default value is
534534
1-Jan-1970.",,No,No,,,,,
535535
DRUG_STRENGTH,valid_end_date,Yes,date,The date when then Concept became invalid.,,No,No,,,,,
536536
DRUG_STRENGTH,invalid_reason,No,varchar(1),"Reason the concept was invalidated. Possible values are D (deleted), U (replaced with an update) or NULL when valid_end_date has the default value.",,No,No,,,,,
537-
COHORT_DEFINITION,cohort_definition_id,Yes,bigint,"This is the identifier given to the cohort, usually by the ATLAS application",,No,No,,,,,
537+
COHORT,cohort_definition_id,Yes,integer,,,No,No,,,,,
538+
COHORT,subject_id,Yes,integer,,,No,No,,,,,
539+
COHORT,cohort_start_date,Yes,date,,,No,No,,,,,
540+
COHORT,cohort_end_date,Yes,date,,,No,No,,,,,
541+
COHORT_DEFINITION,cohort_definition_id,Yes,integer,"This is the identifier given to the cohort, usually by the ATLAS application",,No,Yes,COHORT,COHORT_DEFINITION_ID,,,
538542
COHORT_DEFINITION,cohort_definition_name,Yes,varchar(255),A short description of the cohort,,No,No,,,,,
539543
COHORT_DEFINITION,cohort_definition_description,No,varchar(MAX),A complete description of the cohort.,,No,No,,,,,
540544
COHORT_DEFINITION,definition_type_concept_id,Yes,integer,Type defining what kind of Cohort Definition the record represents and how the syntax may be executed.,,No,Yes,CONCEPT,CONCEPT_ID,,,

inst/csv/OMOP_CDMv6.0_Table_Level.csv

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,4 +76,5 @@ CONCEPT_ANCESTOR,VOCAB,No,,No,,,"The CONCEPT_ANCESTOR table is designed to simpl
7676
This table is entirely derived from the CONCEPT, CONCEPT_RELATIONSHIP and RELATIONSHIP tables.",,
7777
SOURCE_TO_CONCEPT_MAP,VOCAB,No,,No,,,"The source to concept map table is a legacy data structure within the OMOP Common Data Model, recommended for use in ETL processes to maintain local source codes which are not available as Concepts in the Standardized Vocabularies, and to establish mappings for each source code into a Standard Concept as target_concept_ids that can be used to populate the Common Data Model tables. The SOURCE_TO_CONCEPT_MAP table is no longer populated with content within the Standardized Vocabularies published to the OMOP community.",,
7878
DRUG_STRENGTH,VOCAB,No,,No,,,The DRUG_STRENGTH table contains structured content about the amount or concentration and associated units of a specific ingredient contained within a particular drug product. This table is supplemental information to support standardized analysis of drug utilization.,,
79+
COHORT,RESULTS,No,,No,,,The COHORT table contains records of subjects that satisfy a given set of criteria for a duration of time. The definition of the cohort is contained within the COHORT_DEFINITION table. It is listed as part of the RESULTS schema because it is a table that users of the database as well as tools such as ATLAS need to be able to write to. The CDM and Vocabulary tables are all read-only so it is suggested that the COHORT and COHORT_DEFINTION tables are kept in a separate schema to alleviate confusion.,,"Cohorts typically include patients diagnosed with a specific condition, patients exposed to a particular drug, but can also be Providers who have performed a specific Procedure. Cohort records must have a Start Date and an End Date, but the End Date may be set to Start Date or could have an applied censor date using the Observation Period Start Date. Cohort records must contain a Subject Id, which can refer to the Person, Provider, Visit record or Care Site though they are most often Person Ids. The Cohort Definition will define the type of subject through the subject concept id. A subject can belong (or not belong) to a cohort at any moment in time. A subject can only have one record in the cohort table for any moment of time, i.e. it is not possible for a person to contain multiple records indicating cohort membership that are overlapping in time"
7980
COHORT_DEFINITION,VOCAB,No,,No,,,"The COHORT_DEFINITION table contains records defining a Cohort derived from the data through the associated description and syntax and upon instantiation (execution of the algorithm) placed into the COHORT table. Cohorts are a set of subjects that satisfy a given combination of inclusion criteria for a duration of time. The COHORT_DEFINITION table provides a standardized structure for maintaining the rules governing the inclusion of a subject into a cohort, and can store operational programming code to instantiate the cohort within the OMOP Common Data Model.",,

rmd/cdm60.Rmd

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
---
2+
title: "**OMOP CDM v6.0**"
23
output:
34
html_document:
45
toc: true
@@ -18,8 +19,6 @@ library(stringr)
1819
1920
```
2021

21-
# **OMOP CDM v6.0**
22-
2322
## NOTE ABOUT CDM v6.0
2423

2524
Please be aware that v6.0 of the OMOP CDM is **not** fully supported by the OHDSI suite of tools and methods. The major difference in CDM v5.3 and CDM v6.0 involves switching the \*_datetime fields to mandatory rather than optional. This switch radically changes the assumptions related to exposure and outcome timing. Rather than move forward with v6.0, CDM v5.4 was designed with additions to the model that have been requested by the community while retaining the date structure of medical events in v5.3. Please see our the specifications for [CDM v5.4](http://ohdsi.github.io/CommonDataModel/cdm54.html) and detailed [changes from CDM v5.3](http://ohdsi.github.io/CommonDataModel/cdm54Changes.html). **For new collaborators to OHDSI, please transform your data to [CDM v5.4](https://github.com/OHDSI/CommonDataModel/releases/tag/v5.4) until such time that the v6 series of the CDM is ready for mainstream use.**

0 commit comments

Comments
 (0)