| Title: |
IMMZD2DTJEEncounterElements |
| Id: |
IMMZD2DTJEEncounterElements |
| Version: |
0.2.0 |
| Url: |
IMMZD2DTJEEncounterElements |
| Status: |
draft |
| Type: |
system: http://terminology.hl7.org/CodeSystem/library-type
code: logic-library
|
| Date: |
2025-11-25 20:07:03+0000 |
| Publisher: |
WHO |
| Description: |
This library defines encounter-based elements for JE used throughout the Immunization CPG
|
| Related Artifacts: |
Dependencies
|
| Parameters: |
| Name | Type | Min | Max | In/Out |
| Today | date | 0 | 1 | In |
| EncounterId | string | 0 | 1 | In |
| Patient | Patient | 0 | 1 | Out |
| JE Doses Administered to Patient | Immunization | 0 | * | Out |
| JE Primary Series Doses Administered to Patient | Immunization | 0 | * | Out |
| Number of JE Primary Series Doses Administered | integer | 0 | 1 | Out |
| Client's age is less than 6 months | boolean | 0 | 1 | Out |
| No JE primary series doses were administered | boolean | 0 | 1 | Out |
| Client's age is more than or equal to 6 months | boolean | 0 | 1 | Out |
| One JE primary series dose was administered | boolean | 0 | 1 | Out |
| Date of Latest JE Dose | date | 0 | 1 | Out |
| The latest JE dose was administered less than 4 weeks ago | boolean | 0 | 1 | Out |
| The latest JE dose was administered more than 4 weeks ago | boolean | 0 | 1 | Out |
| Two JE primary series doses were administered | boolean | 0 | 1 | Out |
| Client's age is less than 8 months | boolean | 0 | 1 | Out |
| Client's age is more than or equal to 8 months | boolean | 0 | 1 | Out |
| No live vaccine was administered in the last 4 weeks | boolean | 0 | 1 | Out |
| Live vaccine was administered in the last 4 weeks | boolean | 0 | 1 | Out |
| Client's age is less than 9 months | boolean | 0 | 1 | Out |
| Client's age is more than or equal to 9 months | boolean | 0 | 1 | Out |
| One JE primary series doses were administered | boolean | 0 | 1 | Out |
|
| Content: text/cql |
/*
* Library: IMMZD2DTJEEncounterElements
*/
library IMMZD2DTJEEncounterElements
using FHIR version '4.0.1'
include FHIRHelpers version '4.0.1'
include WHOConcepts
include WHOCommon called WC
include WHOElements called WE
include IMMZCommon called Common
include IMMZConcepts called Concepts
include IMMZEncounterElements called Encounter
include IMMZD2DTJEElements called JEElements
parameter Today Date default Today()
parameter EncounterId String
context Patient
/*
@internal: JE containing Doses Administered to Patient
*/
define "JE Doses Administered to Patient":
Encounter."Doses Administered to Patient" I
where
I.vaccineCode in Concepts."JE vaccines"
/*
@internal: JE containing Doses Administered to Patient that are in the Primary series
*/
define "JE Primary Series Doses Administered to Patient":
"JE Doses Administered to Patient".seriesPrimary()
/*
@internal: Number of JE Primary Series doses
*/
define "Number of JE Primary Series Doses Administered":
Count("JE Primary Series Doses Administered to Patient")
/*
@input: Client's age is less than 6 months
@pseudocode: Today's date − "Date of birth" < 6 months
@code: Client's age is less than 6 months-41
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "Client's age is less than 6 months":
Encounter."Current Patient Age In Months" < 6
/*
@input: No JE primary series doses were administered
@pseudocode: Count of vaccines administered (where "Vaccine type" = "JE vaccines" and "Type of dose" = "Primary series") = 0
@code: No JE primary series doses were administered-111
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "No JE primary series doses were administered":
"Number of JE Primary Series Doses Administered" = 0
/*
@input: Client's age is more than or equal to 6 months
@pseudocode: Today's date − "Date of birth" ≥ 6 months
@code: Client's age is more than or equal to 6 months-41
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "Client's age is more than or equal to 6 months":
Encounter."Current Patient Age In Months" >= 6
/*
@input: One JE primary series dose was administered
@pseudocode: Count of vaccines administered (where "Vaccine type" = "JE vaccines" and "Type of dose" = "Primary series") = 1
@code: One JE primary series dose was administered-111
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "One JE primary series dose was administered":
"Number of JE Primary Series Doses Administered" = 1
/*
@input: The latest JE dose was administered less than 4 weeks ago
@pseudocode: Today's date − "Date and time of vaccination" (where "Vaccine type" = "JE vaccines") < 4 weeks
@code: The latest JE dose was administered less than 4 weeks ago-94
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "The latest JE dose was administered less than 4 weeks ago":
"Date of Latest JE Dose" is not null
and duration in weeks between "Date of Latest JE Dose" and Today < 4
/*
@input: The latest JE dose was administered more than 4 weeks ago
@pseudocode: Today's date − "Date and time of vaccination" (where "Vaccine type" = "JE vaccines") ≥ 4 weeks
@code: The latest JE dose was administered more than 4 weeks ago-94
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "The latest JE dose was administered more than 4 weeks ago":
not "The latest JE dose was administered less than 4 weeks ago"
/*
@input: Two JE primary series doses were administered
@pseudocode: Count of vaccines administered (where "Vaccine type" = "JE vaccines" and "Type of dose" = "Primary series") = 2
@code: Two JE primary series doses were administered-111
@decision: IMMZ.D2.DT.JE.Inactivated Vero cell-derived vaccine: Inactivated Vero cell-derived vaccination schedule (2-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "Two JE primary series doses were administered":
"Number of JE Primary Series Doses Administered" = 2
/*
@input: Client's age is less than 8 months
@pseudocode: Today's date − "Date of birth" < 8 months
@code: Client's age is less than 8 months-41
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "Client's age is less than 8 months":
Encounter."Current Patient Age In Months" < 8
/*
@input: Client's age is more than or equal to 8 months
@pseudocode: Today's date − "Date of birth" ≥ 8 months
@code: Client's age is more than or equal to 8 months-41
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "Client's age is more than or equal to 8 months":
Encounter."Current Patient Age In Months" >= 8
/*
@input: No live vaccine was administered in the last 4 weeks
@pseudocode: Today's date − latest "Date and time of vaccination" (where "Vaccine type" = "JE vaccines") ≥ 4 weeks
@code: No live vaccine was administered in the last 4 weeks-101
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "No live vaccine was administered in the last 4 weeks":
Encounter."No live vaccine was administered in the last 4 weeks"
/*
@input: Live vaccine was administered in the last 4 weeks
@pseudocode: Today's date − latest "Date and time of vaccination" (where "Live vaccine" = TRUE) < 4 weeks
@code: Live vaccine was administered in the last 4 weeks-92
@decision: IMMZ.D2.DT.JE.Live attenuated vaccine: Live attenuated vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "Live vaccine was administered in the last 4 weeks":
Encounter."Live vaccine was administered in the last 4 weeks"
/*
@input: Client's age is less than 9 months
@pseudocode: Today's date − "Date of birth" < 9 months
@code: Client's age is less than 9 months-41
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "Client's age is less than 9 months":
Encounter."Current Patient Age In Months" < 9
/*
@input: Client's age is more than or equal to 9 months
@pseudocode: Today's date − "Date of birth" ≥ 9 months
@code: Client's age is more than or equal to 9 months-41
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "Client's age is more than or equal to 9 months":
Encounter."Current Patient Age In Months" >= 9
/*
@input: One JE primary series doses were administered
@pseudocode: Count of vaccines administered (where "Vaccine type" = "JE vaccines" and "Type of dose" = "Primary series") = 1
@code: One JE primary series doses were administered-111
@decision: IMMZ.D2.DT.JE.Live recombinant vaccine: Live recombinant vaccination schedule (1-dose scheme)
JE vaccination should be integrated into national immunization schedules in all areas where JE is recognized as a public health priority
*/
define "One JE primary series doses were administered":
"One JE primary series dose was administered"
/*
@internal: Date of Latest JE Dose
*/
define "Date of Latest JE Dose":
date from start of "JE Doses Administered to Patient".mostRecent().occurrence.toInterval()
|
|
| Content: application/elm+xml |
Encoded data (65360 characters)
|
|