EMIS published data transformation and mapping: Difference between revisions

From Endeavour Knowledge Base
(Created page with " This article describes the mapping of EMIS published data into the intermediate FHIR store. == Clinical Observations == == Content dependent rules == CareRecord_Observatio...")
 
No edit summary
Line 8: Line 8:
CareRecord_Observation contains data which is mapped to multiple FHIR resource types. The target resource type is decided by the following rules, using the Read2 code and CodeType from the Coding_ClinicalCode file (looked up using the CodeId from CareRecord_Observation) and the Value field from CareRecord_Observation.
CareRecord_Observation contains data which is mapped to multiple FHIR resource types. The target resource type is decided by the following rules, using the Read2 code and CodeType from the Coding_ClinicalCode file (looked up using the CodeId from CareRecord_Observation) and the Value field from CareRecord_Observation.


{| border="1" cellpadding="1" cellspacing="1" style="width: 500px;"
 
 
{| border="1" cellpadding="1" cellspacing="1" style="width: 800pt;"
|-
! scope="col" style="text-align: left; background-color: rgb(239, 239, 239); width: 181px;" | Code type Rule
! scope="col" style="width: 150px; background-color: rgb(239, 239, 239);" | Target profile
|-
|-
! Rule
| If the Value is empty, and the CodeType is one of (Biochemistry, Cyology_Histology,Haematology,Immunology,Microbiology,Radiology, Health_Management)
! Target profile
| DiagnosticReport
|-
|-
|  
|  
<span style="line-height:normal">If the Value is empty, and the CodeType is one of (Biochemistry</span>
If the Value is not empty OR the CodeType is one of


<span style="line-height:normal">Cyology_Histology,&nbsp;Haematology,&nbsp;Immunology,&nbsp;Microbiology,&nbsp;Radiology, Health_Management)&nbsp;</span>
(Biochemistry,Biological_Values,Cytology_Histology, Haematology, Health_Management, Immunology,Microbiology,Radiology,Symptoms_Findings, Procedure (note, the codes is this category aren't actually "procedures"), Administration_Documents_Attachments, Body_Structure //dental structures,Care_Episode_Outcome, Dental_Finding,Diagnostics, Discharged_From_Service,EMIS_Qualifier,Ethnicity,HMP,Intervention_Category, Intervention_Target, KC60,;Marital_Status, Nationality,Nursing_Problem, Nursing_Problem_Domain, Obsteterics_Birth,Person_Health_Social, Planned_Dental, Problem_Rating_Scale, Reason_For_Care, Referral_Activity, Referral_Rejected, Referral_Withdrawn, Regiment, Religion, Trade_Branch, Unset)


&nbsp;
|  
 
Observation
| <span style="line-height:normal">DiagnosticReport</span>
|-
| &nbsp;
| &nbsp;
|}
 
&nbsp;


&nbsp;
&nbsp;
Line 32: Line 30:
&nbsp;
&nbsp;


{| class="MsoTableGrid" style="border-collapse:collapse; border:solid windowtext 1.0pt"
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt" width="415" |
| If the CodeType is Conditions_Operations_Procedures and the Code is in (Preventive procedures, Operations, procedures, sites, Other therapeutic procedures)
<span style="line-height:normal">Test</span>
| Procedure
 
| style="width:169.8pt; border:solid windowtext 1.0pt; border-left:none" width="226" |
<span style="line-height:normal">Action</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| If the CodeType is Conditions_Operations_Procedures and the Code is in (Infectious and parasitic diseases, Neoplasms,Endocrine, nutritional, metabolic and immunity disorders, Diseases of blood and blood-forming organs, Mental disorders, Nervous system and sense organ diseases, Circulatory system diseases, Respiratory system diseases, Digestive system diseases, Genitourinary system diseases, Skin and subcutaneous tissue diseases, Musculoskeletal and connective tissue diseases)
<span style="line-height:normal">If the Value is empty, and the CodeType is one of:</span>
|
 
Condition
<span style="line-height:normal">Biochemistry</span>
 
<span style="line-height:normal">Cyology_Histology</span>
 
<span style="line-height:normal">Haematology</span>
 
<span style="line-height:normal">Immunology</span>
 
<span style="line-height:normal">Microbiology</span>
 
<span style="line-height:normal">Radiology</span>
 
<span style="line-height:normal">Health_Management</span>


&nbsp;
&nbsp;
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
<span style="line-height:normal">Map to DiagnosticReport</span>


|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| Else&nbsp;<span style="line-height:normal">If the CodeType is Conditions_Operations_Procedures</span>
<span style="line-height:normal">If the Value is not empty or the CodeType is one of:</span>
| Observation
 
<span style="line-height:normal">Biochemistry</span>
 
<span style="line-height:normal">Biological_Values</span>
 
<span style="line-height:normal">Cyology_Histology</span>
 
<span style="line-height:normal">Haematology</span>
 
<span style="line-height:normal">Health_Management</span>
 
<span style="line-height:normal">Immunology</span>
 
<span style="line-height:normal">Microbiology</span>
 
<span style="line-height:normal">Radiology</span>
 
<span style="line-height:normal">Symptoms_Findings</span>
 
<span style="line-height:normal">Procedure (note, the codes is this category aren't actually "procedures")</span>
 
<span style="line-height:normal">Adminisation_Documents_Attachments</span>
 
<span style="line-height:normal">Body_Structure //dental structures</span>
 
<span style="line-height:normal">Care_Episode_Outcome</span>
 
<span style="line-height:normal">Dental_Finding</span>
 
<span style="line-height:normal">Diagnostics</span>
 
<span style="line-height:normal">Discharged_From_Service</span>
 
<span style="line-height:normal">EMIS_Qualifier</span>
 
<span style="line-height:normal">Ethnicity</span>
 
<span style="line-height:normal">HMP</span>
 
<span style="line-height:normal">Intervention_Category</span>
 
<span style="line-height:normal">Intervention_Target</span>
 
<span style="line-height:normal">KC60</span>
 
<span style="line-height:normal">Marital_Status</span>
 
<span style="line-height:normal">Nationality</span>
 
<span style="line-height:normal">Nursing_Problem</span>
 
<span style="line-height:normal">Nursing_Problem_Domain</span>
 
<span style="line-height:normal">Obsteterics_Birth</span>
 
<span style="line-height:normal">Person_Health_Social</span>
 
<span style="line-height:normal">Planned_Dental</span>
 
<span style="line-height:normal">Problem_Rating_Scale</span>
 
<span style="line-height:normal">Reason_For_Care</span>
 
<span style="line-height:normal">Referral_Activity</span>
 
<span style="line-height:normal">Referral_Rejected</span>
 
<span style="line-height:normal">Referral_Withdrawn</span>
 
<span style="line-height:normal">Regiment</span>
 
<span style="line-height:normal">Religion</span>
 
<span style="line-height:normal">Trade_Branch</span>
 
<span style="line-height:normal">Unset</span>
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
<span style="line-height:normal">Map to Observation</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| If the CodeType is any of (Allergy_Adverse_Drug_Reations, Allergy_Adverse_Reations)
<span style="line-height:normal">If the CodeType is Conditions_Operations_Procedures and the Code is in these branches:</span>
| AllergyIntolerance
 
<span style="line-height:normal">6....&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Preventive procedures</span>
 
<span style="line-height:normal">7....&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Operations, procedures, sites</span>
 
<span style="line-height:normal">8....&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Other therapeutic procedures</span>
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |  
<span style="line-height:normal">Map to Procedure</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| If the CodeType is any of (Dental_Disorder, Dental_Procedure)
<span style="line-height:normal">If the CodeType is Conditions_Operations_Procedures and the Code is in these branches:</span>
| Conidition
 
<span style="line-height:normal">A....&nbsp;&nbsp;&nbsp; Infectious and parasitic diseases</span>
 
<span style="line-height:normal">B....&nbsp;&nbsp;&nbsp; Neoplasms</span>
 
<span style="line-height:normal">C....&nbsp;&nbsp;&nbsp; Endocrine, nutritional, metabolic and immunity disorders</span>
 
<span style="line-height:normal">D....&nbsp;&nbsp;&nbsp; Diseases of blood and blood-forming organs</span>
 
<span style="line-height:normal">E....&nbsp;&nbsp;&nbsp; Mental disorders</span>
 
<span style="line-height:normal">F....&nbsp;&nbsp;&nbsp; Nervous system and sense organ diseases</span>
 
<span style="line-height:normal">G....&nbsp;&nbsp;&nbsp; Circulatory system diseases</span>
 
<span style="line-height:normal">H....&nbsp;&nbsp;&nbsp; Respiratory system diseases</span>
 
<span style="line-height:normal">J....&nbsp;&nbsp;&nbsp; Digestive system diseases</span>
 
<span style="line-height:normal">K....&nbsp;&nbsp;&nbsp; Genitourinary system diseases</span>
 
<span style="line-height:normal">M....&nbsp;&nbsp;&nbsp; Skin and subcutaneous tissue diseases</span>
 
<span style="line-height:normal">N....&nbsp;&nbsp;&nbsp; Musculoskeletal and connective tissue diseases</span>
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |  
<span style="line-height:normal">Map to Condition*</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| If the CodeType is (Family_History)
<span style="line-height:normal">If the CodeType is Conditions_Operations_Procedures</span>
| FamilyMemberHistory<br/> &nbsp;
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
<span style="line-height:normal">Map to Observation</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| f the CodeType is (Immunisations)
<span style="line-height:normal">If the CodeType is any of:</span>
| Immunization
 
<span style="line-height:normal">Allergy_Adverse_Drug_Reations</span>
 
<span style="line-height:normal">Allergy_Adverse_Reations</span>
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
<span style="line-height:normal">Map to AllergyIntolerance</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| If code type is (Investigation_Requests)
<span style="line-height:normal">If the CodeType is any of:</span>
| DiagnosticOrder
 
<span style="line-height:normal">Dental_Disorder</span>
 
<span style="line-height:normal">Dental_Procedure</span>
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
<span style="line-height:normal">Map to Condition*</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| If code type is Pathology_Specimen
<span style="line-height:normal">If the CodeTyps is</span>
| Specimen
 
<span style="line-height:normal">Family_History</span>
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
<span style="line-height:normal">Map to FamilyMemberHistory</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| If code type is Referral
<span style="line-height:normal">If the CodeType is</span>
| Referral request
 
|}
<span style="line-height:normal">Immunisations</span>


&nbsp;
&nbsp;


| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
{| border="1" cellpadding="1" cellspacing="1" style="width: 800pt;"
<span style="line-height:normal">Map to Immunization</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |  
! scope="col" style="text-align: left; background-color: rgb(239, 239, 239); width: 181px;" | Structural Rule
<span style="line-height:normal">If the CodeType is</span>
! scope="col" style="width: 150px; background-color: rgb(239, 239, 239);" | Target profile
 
<span style="line-height:normal">Investigation_Requests</span>
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |  
<span style="line-height:normal">Map to DiagnosticOrder</span>
 
|-
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
| the Condition resource uses the “problem” profile, otherwise it uses the “condition” profile.  
<span style="line-height:normal">If the CodeType is</span>
In addition to the above mappings, if the target resource selects ''is not'' condition, but the CareRecord_Observation is linked to by a CareRecord_Problem record, then a condition resource will also be created, with the “problem” profile
 
<span style="line-height:normal">Pathology_Specimen</span>
 
&nbsp;
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
<span style="line-height:normal">Map to Specimen</span>
 
|-
| style="width:311.6pt; border:solid windowtext 1.0pt; border-top:none" width="415" |
<span style="line-height:normal">If the CodeType is</span>
 
<span style="line-height:normal">Referral</span>
 
| style="width:169.8pt; border-top:none; border-left:none; border-bottom:solid windowtext 1.0pt; border-right:solid windowtext 1.0pt" width="226" |
<span style="line-height:normal">Map to ReferralRequest</span>


| Condition
|}
|}
&nbsp;
*If the CareRecord_Observation is linked to by a CareRecord_Problem record, then the Condition resource uses the “problem” profile, otherwise it uses the “condition” profile.
In addition to the above mappings, if the target resource selects ''is not'' condition, but the CareRecord_Observation is linked to by a CareRecord_Problem record, then a condition resource will also be created, with the “problem” profile.


&nbsp;
&nbsp;

Revision as of 16:22, 5 May 2020

This article describes the mapping of EMIS published data into the intermediate FHIR store.

Clinical Observations

Content dependent rules

CareRecord_Observation contains data which is mapped to multiple FHIR resource types. The target resource type is decided by the following rules, using the Read2 code and CodeType from the Coding_ClinicalCode file (looked up using the CodeId from CareRecord_Observation) and the Value field from CareRecord_Observation.

 

Code type Rule Target profile
If the Value is empty, and the CodeType is one of (Biochemistry, Cyology_Histology,Haematology,Immunology,Microbiology,Radiology, Health_Management) DiagnosticReport

If the Value is not empty OR the CodeType is one of

(Biochemistry,Biological_Values,Cytology_Histology, Haematology, Health_Management, Immunology,Microbiology,Radiology,Symptoms_Findings, Procedure (note, the codes is this category aren't actually "procedures"), Administration_Documents_Attachments, Body_Structure //dental structures,Care_Episode_Outcome, Dental_Finding,Diagnostics, Discharged_From_Service,EMIS_Qualifier,Ethnicity,HMP,Intervention_Category, Intervention_Target, KC60,;Marital_Status, Nationality,Nursing_Problem, Nursing_Problem_Domain, Obsteterics_Birth,Person_Health_Social, Planned_Dental, Problem_Rating_Scale, Reason_For_Care, Referral_Activity, Referral_Rejected, Referral_Withdrawn, Regiment, Religion, Trade_Branch, Unset)

Observation

 

 

If the CodeType is Conditions_Operations_Procedures and the Code is in (Preventive procedures, Operations, procedures, sites, Other therapeutic procedures) Procedure
If the CodeType is Conditions_Operations_Procedures and the Code is in (Infectious and parasitic diseases, Neoplasms,Endocrine, nutritional, metabolic and immunity disorders, Diseases of blood and blood-forming organs, Mental disorders, Nervous system and sense organ diseases, Circulatory system diseases, Respiratory system diseases, Digestive system diseases, Genitourinary system diseases, Skin and subcutaneous tissue diseases, Musculoskeletal and connective tissue diseases)

Condition

 

Else If the CodeType is Conditions_Operations_Procedures Observation
If the CodeType is any of (Allergy_Adverse_Drug_Reations, Allergy_Adverse_Reations) AllergyIntolerance
If the CodeType is any of (Dental_Disorder, Dental_Procedure) Conidition
If the CodeType is (Family_History) FamilyMemberHistory
 
f the CodeType is (Immunisations) Immunization
If code type is (Investigation_Requests) DiagnosticOrder
If code type is Pathology_Specimen Specimen
If code type is Referral Referral request

 

Structural Rule Target profile
the Condition resource uses the “problem” profile, otherwise it uses the “condition” profile.

In addition to the above mappings, if the target resource selects is not condition, but the CareRecord_Observation is linked to by a CareRecord_Problem record, then a condition resource will also be created, with the “problem” profile

Condition

 

Prescribing_DrugRecord End Dates

The Prescribing_DrugRecord file contains both a Boolean active indicator (IsActive) and the medication end date (CancellationDate). Within Emis Web, it’s the IsActive indicator that is used to determine whether medication is active or not, the CancellationDate just providing additional information for ended medication. Analysing the received data has highlighted that there are a number of cases where the CancellationDate doesn’t match what the IsActive flag states:

  1. IsActive = true but a CancellationDate is present;
  2. IsActive = false but a CancellationDate is absent.

From the dates of affected data, these appear to be related to either a service moving to Emis Web from another GP system, and are an artefact of that transfer.

To ensure consistency in the FHIR MedicationStatements created from this file, the Cancellation date will only be carried over if the DrugRecord is non-active. If no cancellation date is present, it will be derived from the medication start and course length (found from the associated Prescribing_IssueRecord file).