# Standard and non-standard codes

Atlas uses the Observational Medical Outcomes Partnership (OMOP) common data model ([OMOP-CDM](https://www.ohdsi.org/data-standardization/the-common-data-model/)). Atlas cohorts can be created using both standard and non-standard codes.

{% hint style="info" %}
Medical codes from OHDSI standardized vocabularies are called **standard codes**. Other medical codes are called **non-standard codes**. We recommend using the standard codes except in specific circumstances (e.g. FGVisitType).
{% endhint %}

### Advantages of standard codes

* Phenotype data can be combined across multiple sources using standard codes (e.g. FinnGen and UKBB).
* Standard codes are organized into hierarchies and allow cohorts to be created at different levels of these hierarchies.
* Some standard codes (e.g. drug [ATC codes](/finngen-data-specifics/finnish-health-registers-and-medical-coding/international-and-finnish-health-code-sets.md)) are grouped into alternative hierarchies using classification codes.
* Standard codes are divided into [domains](https://www.ohdsi.org/web/wiki/doku.php?id=documentation:vocabulary:domains) (e.g. condition, drug, procedure, observation).

### Advantages of non-standard codes

* Some non-standard codes are more specific than the standard codes they have been mapped to
* Some non-standard codes may not have a mapping to standard codes
* Some non-standard codes are organized into hierarchies

### Mapping non-standard codes to standard codes

FinnGen contains medical codes from several national registers. In addition to standard OHDSI vocabularies, FinnGen uses Finnish national vocabularies from FinOMOP and FinnGen-specific vocabularies. All these vocabularies are loaded into FinnGen Atlas to allow cohorts to be created using both standard and non-standard codes.

The mapping of non-standard codes to standard codes is explained in detail in [FinnGen ETL to OMOP CDM](https://finngen.github.io/ETL). FinOMOP maintains a [report](https://finngen.github.io/FinOMOP_OMOP_vocabulary/StatusReport/dashboard.html#databases-coverage) that shows the percentage of codes in non-standard vocabularies mapped to standard OHDSI vocabularies.

### **Standard vocabularies**

Standard OHDSI vocabularies used in FinnGen are explained in [FinnGen ETL to OMOP CDM](https://finngen.github.io/ETL/appendix_vocabularies.html) and listed in the table below:

| **Vocabulary**       | **Description**                                                                                        |
| -------------------- | ------------------------------------------------------------------------------------------------------ |
| SNOMED               | Systematic Nomenclature of Medicine - Clinical Terms (IHTSDO)                                          |
| ICD9CM               | International Classification of Diseases, Ninth Revision, Clinical Modification, Volume 1 and 2 (NCHS) |
| ICD9Proc             | International Classification of Diseases, Ninth Revision, Clinical Modification, Volume 3 (NCHS)       |
| CPT4                 | Current Procedural Terminology version 4 (AMA)                                                         |
| HCPCS                | Healthcare Common Procedure Coding System (CMS)                                                        |
| LOINC                | Logical Observation Identifiers Names and Codes (Regenstrief Institute)                                |
| RxNorm               | RxNorm (NLM)                                                                                           |
| NDC                  | National Drug Code (FDA and manufacturers)                                                             |
| Gender               | OMOP Gender                                                                                            |
| Race                 | Race and Ethnicity Code Set (USBC)                                                                     |
| CMS Place of Service | Place of Service Codes for Professional Claims (CMS)                                                   |
| ATC                  | WHO Anatomic Therapeutic Chemical Classification                                                       |
| ICD10                | International Classification of Diseases, Tenth Revision (WHO)                                         |
| ICD10PCS             | ICD-10 Procedure Coding System (CMS)                                                                   |
| Revenue Code         | UB04/CMS1450 Revenue Codes (CMS)                                                                       |
| Ethnicity            | OMOP Ethnicity                                                                                         |
| NUCC                 | National Uniform Claim Committee Health Care Provider Taxonomy Code Set (NUCC)                         |
| Medicare Specialty   | Medicare provider/supplier specialty codes (CMS)                                                       |
| SPL                  | Structured Product Labeling (FDA)                                                                      |
| OPCS4                | OPCS Classification of Interventions and Procedures version 4 (NHS)                                    |
| HES Specialty        | Hospital Episode Statistics Specialty (NHS)                                                            |
| Currency             | International Currency Symbol (ISO 4217)                                                               |
| ABMS                 | Provider Specialty (American Board of Medical Specialties)                                             |
| RxNorm Extension     | RxNorm Extension (OHDSI)                                                                               |
| NAACCR               | Data Standards & Data Dictionary Volume II (NAACCR)                                                    |
| Nebraska Lexicon     | Nebraska Lexicon                                                                                       |
| OMOP Extension       | OMOP Extension (OHDSI)                                                                                 |
| CAP                  | CAP electronic Cancer Checklists (College of American Pathologists)                                    |
| CIM10                | International Classification of Diseases, Tenth Revision, French Edition                               |
| NCCD                 | Normalized Chinese Clinical Drug                                                                       |
| OMOP Genomic         | OMOP Genomic vocabulary                                                                                |
| UCUM                 | Unified Code for Units of Measure (Regenstrief Institute)                                              |
| ICDO3                | International Classification of Diseases for Oncology, 3rd Edition                                     |

### **Non-standard vocabularies**

Non-standard vocabularies used in FinnGen are explained in [FinnGen ETL to OMOP CDM](https://finngen.github.io/ETL/appendix_vocabularies.html) and listed in the table below:

| **Vocabulary**       | **Description**                                                                                                  |
| -------------------- | ---------------------------------------------------------------------------------------------------------------- |
| FHL                  | Finnish Hospital League                                                                                          |
| ICD8fi               | International Classification of Diseases, Eight Revision (Finland)                                               |
| HPN                  | Heart Patients Codes (New)                                                                                       |
| ICD9fi               | International Classification of Diseases, Ninth Revision (Finland)                                               |
| ICD10fi              | International Classification of Diseases, Tenth Revision (Finland)                                               |
| MEDSPECfi            | Medical Specialty Finland                                                                                        |
| MICROBEfi            | Microbial Codes Finland                                                                                          |
| MICROBEfi\_TKU       | Microbial Codes Finland, Turku Hospital Extension                                                                |
| NCSPfi               | NOMESCO Classification of Surgical Procedures (Finland)                                                          |
| SNOMED2fi            | Systematic Nomenclature of Medicine, Second Edition (Finland)                                                    |
| ProcedureModifier    | Procedure Modifier                                                                                               |
| REIMB                | Kela Reimbursement Codes                                                                                         |
| SPAT                 | SPAT Procedure Codes For Primary Care                                                                            |
| VNRfi                | Nordic Article Number (Finland)                                                                                  |
| ICPC                 | International Classification of Primary Care                                                                     |
| HPO                  | Heart Patients Codes (Old)                                                                                       |
| ProfessionalCode     | Professional Code                                                                                                |
| FGVisitType          | FinnGen Visit Type                                                                                               |
| LABfi\_ALL           | Laboratory Codes Finland. Improved by combining codes LABfi, LABfi\_TMP, LABfi\_TKU and LABfi\_HUS vocabularies. |
| UNITfi\_ALL          | Units Finland. Taken from UNITfi vocabulary and improved for FinnGen Kanta data registry.                        |
| KantaServiceProvider | Service provider extracted from CODING\_SYSTEM\_OID column within FinnGen Kanta registry                         |

### Atlas Search

In Atlas, three types of codes are displayed using different colours:

* non-standard codes are in red
* standard codes are in blue
* classification codes are in purple

![](/files/N0tBPAGEE4ryWhEJ8tUK)

![](/files/ZOehS5oS2fm2dE17tKvp)

From DF11 onwards drug codes in Atlas are VNR codes. To use ATC codes user can select to [include descendants](/working-in-the-sandbox/which-tools-are-available/atlas/detailed-guide/how-to-define-a-cohort-in-atlas/concept-sets/selecting-descendants-for-a-concept-set-in-atlas.md) in the [Concept Set ](/working-in-the-sandbox/which-tools-are-available/atlas/detailed-guide/how-to-define-a-cohort-in-atlas/concept-sets.md)to allow translation from ATC to VNR codes.

### Atlas Cohort Definitions

In Atlas, a cohort definition starts by creating a **Concept Set** of medical codes of interest. The Concept Set is then used to create cohorts using additional criteria defined in **Cohort Definitions**.

{% hint style="info" %}
Do not mix both standard and non-standard codes in the same Concept Set (see common mistakes below for more information).
{% endhint %}

Standard codes are given as "**condition/procedure/observation**" values while non-standard codes are given as "**Source Concept**" values.

Detailed instructions on how to define standard and non-standard codes in different circumstances are available [here](/working-in-the-sandbox/which-tools-are-available/atlas/detailed-guide/how-to-define-a-cohort-in-atlas/cohort-definitions/mapping-between-atlas-registries-and-medical-codes.md).

For example, when defining **Inclusion Criteria** in the example below:

* standard codes are defined in the "**condition occurrence of**" box
* non-standard codes are defined in the "**Condition Source Concept"** box

![](/files/Gk2y9V5MgLMa1w5RGJa0)

When defining **Cohort Entry Events** in the example below:

* standard codes are defined in the "**procedure occurrence of**" box
* non-standard codes are defined in the "**Procedure Source Concept"** box

![](/files/xrSUrPmB8YQCHlLD5vYz)

#### Mixing standard and non-standard codes

To use both standard and non-standard codes at the same time, separate criteria must be defined for the standard and non-standard codes.

In the example below, we have created two **Inclusion Criteria**; the first for standard and the second for non-standard codes:

![](/files/79OZ4GYde9pIY2s1nibt)

#### Common mistakes

{% hint style="info" %}
A common mistake is to define both standard and non-standard codes using the same criteria. This will select patients that have **both** standard and non-standard codes instead of patients with **either** standard or non-standard codes.
{% endhint %}

If you define both standard and non-standard codes using the same criteria then the search will first create a group of patients that have the standard codes and then from this group select only those patients that also have the non-standard codes. As a result, we have patients with **both** standard and non-standard codes instead of patients with standard **or** non-standard codes.

Do not define both standard and non-standard codes using the same criteria:

![](/files/MgJneDMXiDxufcH1RNcp)

{% hint style="info" %}
Another common mistake is to create a Concept Set with both standard and non-standard codes.
{% endhint %}

Another common mistake is to create a Concept Set with mixed standard and non-standard codes and then use this Concept Set in the "**condition/procedure/observation**" or the "**Source Concept**" box. This search will result in patients with **either** standard or non-standard codes depending on which box was used.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.finngen.fi/working-in-the-sandbox/which-tools-are-available/atlas/detailed-guide/code-sets-in-atlas.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
