Skip to content

Commit

Permalink
Updated measles CQL/Library files for updated expression names from t…
Browse files Browse the repository at this point in the history
…he L2.
  • Loading branch information
lukeaduncan committed Jan 22, 2024
1 parent 7d6e5a2 commit 20d4904
Show file tree
Hide file tree
Showing 14 changed files with 95 additions and 416 deletions.
12 changes: 6 additions & 6 deletions input/cql/IMMZD2DTMeaslesDose0.cql
Original file line number Diff line number Diff line change
Expand Up @@ -65,32 +65,32 @@ define "Client not due for MCV0 Case 1":
@pseudocode: "Immunization recommendation status" = 'Not due'
*/
define "Client not due for MCV0 Case 2":
input."MCV0 dose was NOT administered"
input."MCV0 was not administered"
and input."Client's age is between 6 months and 9 months"
and input."Live vaccine was administered in the last four weeks"
and input."Live vaccine was administered in the last 4 weeks"

/*
@output: Client not due for MCV0 Case 3
@pseudocode: "Immunization recommendation status" = 'Not due'"
*/
define "Client not due for MCV0 Case 3":
input."Client's age is more than 9 months"
input."Client's age is more than or equal to 9 months"

/*
@output: Client not due for MCV0 Case 4
@pseudocode: "Immunization recommendation status" = 'Not due'"
*/
define "Client not due for MCV0 Case 4":
input."MCV0 dose was administered"
input."MCV0 was administered"

/*
@output: Consider MCV0. Create a clinical note.
@pseudocode: "Immunization recommendation status" = 'Further evaluation needed'
*/
define "Consider MCV0. Create a clinical note.":
input."No dose from primary MCV dose series administered"
input."No measles primary series doses were administered"
and input."Client's age is between 6 months and 9 months"
and input."No live vaccine was administered in the last four weeks"
and input."No live vaccine was administered in the last 4 weeks"

/*
@output: Consider MCV0. Create a clinical note. Guidance
Expand Down
26 changes: 13 additions & 13 deletions input/cql/IMMZD2DTMeaslesHighTx.cql
Original file line number Diff line number Diff line change
Expand Up @@ -68,18 +68,18 @@ define "Client is not due for MCV1 Case 1":
@pseudocode: "Immunization recommendation status" = 'Not due'
*/
define "Client is not due for MCV1 Case 2":
input."No dose from primary MCV dose series administered"
and input."Client's age is more than 9 months"
and input."Live vaccine was administered in the last four weeks"
input."No measles primary series doses were administered"
and input."Client's age is more than or equal to 9 months"
and input."Live vaccine was administered in the last 4 weeks"

/*
@output: Client is due for MCV1
@pseudocode: "Immunization recommendation status" = 'Due'
*/
define "Client is due for MCV1":
input."No dose from primary MCV dose series administered"
and input."Client's age is more than 9 months"
and input."No live vaccine was administered in the last four weeks"
input."No measles primary series doses were administered"
and input."Client's age is more than or equal to 9 months"
and input."No live vaccine was administered in the last 4 weeks"

/*
@output: Client is due for MCV1 Guidance
Expand Down Expand Up @@ -122,9 +122,9 @@ define "Client is not due for MCV2 Guidance":
@guidance:Should vaccinate client for MCV2 as client is within appropriate age range and no live vaccine administered in the last 4 weeks. Check for contraindications.
*/
define "Client is due for MCV2":
input."One dose from primary MCV dose series administered High Tx"
and input."Client's age is more than 15 months"
and input."No live vaccine was administered in the last four weeks"
input."MCV1 was administered High Tx"
and input."Client's age is more than or equal to 15 months"
and input."No live vaccine was administered in the last 4 weeks"

/*
@output: Client is due for MCV2 Guidance
Expand All @@ -140,16 +140,16 @@ define "Client is due for MCV2 Guidance":
@pseudocode: "Immunization recommendation status" = 'Not due'
*/
define "Client is not due for MCV2 Case 2":
input."One dose from primary MCV dose series administered High Tx"
and input."Client's age is more than 15 months"
and input."Live vaccine was administered in the last four weeks"
input."MCV1 was administered High Tx"
and input."Client's age is more than or equal to 15 months"
and input."Live vaccine was administered in the last 4 weeks"

/*
@output: Routine immunization schedule complete
@pseudocode: "Completed the primary vaccination series" = TRUE (where "Vaccine type" = "Measles containing vaccines")
*/
define "Routine immunization schedule complete":
input."Two doses from primary MCV dose series administered High Tx"
input."MCV2 was administered High Tx"

/*
@output: Routine immunization schedule complete Guidance
Expand Down
56 changes: 28 additions & 28 deletions input/cql/IMMZD2DTMeaslesInput.cql
Original file line number Diff line number Diff line change
Expand Up @@ -25,53 +25,53 @@ define "MCV Doses Administered to Patient":
I.vaccineCode in IMMZc."MCV Vaccine"

/*
@input: No dose from primary MCV dose series administered
@input: No measles primary series doses were administered
@psuedocode: Count of vaccines administered (where "Vaccine type" = 'Measles containing vaccines' and "Type of dose" = "Primary series" ) = 0
*/
define "No dose from primary MCV dose series administered":
define "No measles primary series doses were administered":
not exists("MCV Doses Administered to Patient" I where I.occurrence after Patient.birthDate + 9 months)

/*
@input: MCV0 dose was administered
@input: MCV0 was administered
@pseudocode: Count of vaccines administered (where "Vaccine type" = 'Measles containing vaccines' and "Type of dose" = "Dose 0") = 1
*/
define "MCV0 dose was administered":
define "MCV0 was administered":
Count("MCV Doses Administered to Patient" I where I.occurrence between Patient.birthDate + 6 months and Patient.birthDate + 9 months) >= 1

/*
@input: MCV0 dose was NOT administered
@input: MCV0 was not administered
@psuedocode: Count of vaccines administered (where "Vaccine type" = 'Measles containing vaccines' and "Type of dose" = "Dose 0") = 0
*/
define "MCV0 dose was NOT administered":
Not("MCV0 dose was administered")
define "MCV0 was not administered":
Not("MCV0 was administered")

/*
@input: One dose from primary MCV dose series administered High Tx
@input: MCV1 was administered High Tx
@pseudocode: Count of vaccines administered (where "Vaccine type" = 'Measles containing vaccines' and "Type of dose" = "Primary series" ) = 1
*/
define "One dose from primary MCV dose series administered High Tx":
define "MCV1 was administered High Tx":
Count("MCV Doses Administered to Patient" I where I.occurrence after Patient.birthDate + 9 months) = 1

/*
@input: Two doses from primary MCV dose series administered High Tx
@input: MCV2 was administered High Tx
@pseudocode: Count of vaccines administered (where "Vaccine type" = 'Measles containing vaccines' and "Type of dose" = "Primary series" ) = 2
*/
define "Two doses from primary MCV dose series administered High Tx":
define "MCV2 was administered High Tx":
Count("MCV Doses Administered to Patient" I where I.occurrence after Patient.birthDate + 9 months) >= 2
and Count("MCV Doses Administered to Patient" I where I.occurrence after Patient.birthDate + 15 months) >= 1

/*
@input: One dose from primary MCV dose series administered Low Tx
@input: MCV1 was administered Low Tx
@pseudocode: Count of vaccines administered (where "Vaccine type" = 'Measles containing vaccines' and "Type of dose" = "Primary series" ) = 1
*/
define "One dose from primary MCV dose series administered Low Tx":
define "MCV1 was administered Low Tx":
Count("MCV Doses Administered to Patient" I where I.occurrence after Patient.birthDate + 12 months) = 1

/*
@input: Two doses from primary MCV dose series administered Low Tx
@input: MCV2 was administered Low Tx
@pseudocode: Count of vaccines administered (where "Vaccine type" = 'Measles containing vaccines' and "Type of dose" = "Primary series" ) = 2
*/
define "Two doses from primary MCV dose series administered Low Tx":
define "MCV2 was administered Low Tx":
Count("MCV Doses Administered to Patient" I where I.occurrence after Patient.birthDate + 12 months) >= 2
and Count("MCV Doses Administered to Patient" I where I.occurrence after Patient.birthDate + 15 months) >= 1

Expand All @@ -83,25 +83,25 @@ define "Measles supplementary dose was administered":
Count("MCV Doses Administered to Patient" I where I.occurrence after Patient.birthDate + 9 months) >= 3

/*
@input: Measles supplementary dose was NOT administered
@input: Measles supplementary dose was not administered
@pseudocode: Count of vaccines administered (where "Vaccine type" = 'Measles containing vaccines' and "Type of dose" = "Supplementary dose") = 0
*/
define "Measles supplementary dose was NOT administered":
define "Measles supplementary dose was not administered":
Not("Measles supplementary dose was administered")

/*
@input: Measles routine immunization schedule is complete High Tx
@pseudocode: "Completed the primary vaccination series" = TRUE (where "Vaccine type" = "Measles containing vaccines")
*/
define "Measles routine immunization schedule is complete High Tx":
"Two doses from primary MCV dose series administered High Tx"
"MCV2 was administered High Tx"

/*
@input: Measles routine immunization schedule is complete Low Tx
@pseudocode: "Completed the primary vaccination series" = TRUE (where "Vaccine type" = "Measles containing vaccines")
*/
define "Measles routine immunization schedule is complete Low Tx":
"Two doses from primary MCV dose series administered Low Tx"
"MCV2 was administered Low Tx"

/*
@input: Client's age is less than 6 months
Expand All @@ -125,10 +125,10 @@ define "Client's age is less than 9 months":
IMMZCom."Current Patient Age In Months" < 9

/*
@input: Client's age is more than 9 months
@input: Client's age is more than or equal to 9 months
@pseudocode: Today's date - "Date of birth" ≥ 9 'month'
*/
define "Client's age is more than 9 months":
define "Client's age is more than or equal to 9 months":
not ("Client's age is less than 9 months")

/*
Expand All @@ -139,10 +139,10 @@ define "Client's age is less than 12 months":
IMMZCom."Current Patient Age In Months" < 12

/*
@input: Client's age is more than 12 months
@input: Client's age is more than or equal to 12 months
Today's date - ""Date of birth"" ≥ 12 'month'
*/
define "Client's age is more than 12 months":
define "Client's age is more than or equal to 12 months":
not("Client's age is less than 12 months")

/*
Expand All @@ -154,25 +154,25 @@ define "Client's age is less than 15 months":
IMMZCom."Current Patient Age In Months" < 15

/*
@input: Client's age is more than 15 months
@input: Client's age is more than or equal to 15 months
@psuedocode: Today's date - "Date of birth" ≥ 15 'month'
*/
define "Client's age is more than 15 months":
define "Client's age is more than or equal to 15 months":
not("Client's age is less than 15 months")

/*
@input: Live vaccine was administered in the last four weeks
@pseudocode: Today's date - latest "Date and time of vaccination" (where "Live vaccine" = TRUE) < 4 'week'
*/
define "Live vaccine was administered in the last four weeks":
define "Live vaccine was administered in the last 4 weeks":
IMMZCom."Date of Latest Live Attenuated Vaccine" is not null and IMMZCom."Date of Latest Live Attenuated Vaccine" + 4 weeks > Now()

/*
@input: No live vaccine was administered in the last four weeks
@pseudocode: Today's date - latest "Date and time of vaccination" (where "Live vaccine" = TRUE) ≥ 4 'week'
*/
define "No live vaccine was administered in the last four weeks":
not("Live vaccine was administered in the last four weeks")
define "No live vaccine was administered in the last 4 weeks":
not("Live vaccine was administered in the last 4 weeks")

/*
@input: The client is pregnant
Expand Down
26 changes: 13 additions & 13 deletions input/cql/IMMZD2DTMeaslesLowTx.cql
Original file line number Diff line number Diff line change
Expand Up @@ -67,18 +67,18 @@ define "Client is not due for MCV1 Case 1":
@pseudocode: "Immunization recommendation status" = 'Not due'
*/
define "Client is not due for MCV1 Case 2":
input."No dose from primary MCV dose series administered"
and input."Client's age is more than 12 months"
and input."Live vaccine was administered in the last four weeks"
input."No measles primary series doses were administered"
and input."Client's age is more than or equal to 12 months"
and input."Live vaccine was administered in the last 4 weeks"

/*
@output: Client is due for MCV1
@pseudocode: "Immunization recommendation status" = 'Due'
*/
define "Client is due for MCV1":
input."No dose from primary MCV dose series administered"
and input."Client's age is more than 12 months"
and input."No live vaccine was administered in the last four weeks"
input."No measles primary series doses were administered"
and input."Client's age is more than or equal to 12 months"
and input."No live vaccine was administered in the last 4 weeks"

/*
@output: Client is due for MCV1 Guidance
Expand Down Expand Up @@ -121,9 +121,9 @@ define "Client is not due for MCV2 Guidance":
@guidance: MCV2 was NOT administered for the client. No live vaccine administered in the last 4 weeks. Client is due for MCV2.
*/
define "Client is due for MCV2":
input."One dose from primary MCV dose series administered Low Tx"
and input."Client's age is more than 15 months"
and input."No live vaccine was administered in the last four weeks"
input."MCV1 was administered Low Tx"
and input."Client's age is more than or equal to 15 months"
and input."No live vaccine was administered in the last 4 weeks"

/*
@output: Client is due for MCV2 Guidance
Expand All @@ -139,16 +139,16 @@ define "Client is due for MCV2 Guidance":
@pseudocode: "Immunization recommendation status" = 'Not due'
*/
define "Client is not due for MCV2 Case 2":
input."One dose from primary MCV dose series administered Low Tx"
and input."Client's age is more than 15 months"
and input."Live vaccine was administered in the last four weeks"
input."MCV1 was administered Low Tx"
and input."Client's age is more than or equal to 15 months"
and input."Live vaccine was administered in the last 4 weeks"

/*
@output: Routine immunization schedule complete
@pseudocode: "Completed the primary vaccination series" = TRUE (where "Vaccine type" = "Measles containing vaccines")
*/
define "Routine immunization schedule complete":
input."Two doses from primary MCV dose series administered Low Tx"
input."MCV2 was administered Low Tx"

/*
@output: Routine immunization schedule complete Guidance
Expand Down
8 changes: 4 additions & 4 deletions input/cql/IMMZD2DTMeaslesSupp.cql
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@ define "Guidance":
@pseudocode: "Immunization recommendation status" = 'Not due'
*/
define "Client not due for measles supplementary dose":
input."Measles supplementary dose was NOT administered"
input."Measles supplementary dose was not administered"
and input."Measles routine immunization schedule is complete High Tx"
and input."Live vaccine was administered in the last four weeks"
and input."Live vaccine was administered in the last 4 weeks"

/*
@output: Client not due for measles supplementary dose Guidance
Expand All @@ -55,9 +55,9 @@ define "Client not due for measles supplementary dose Guidance":
@pseudocode: "Immunization recommendation status" = 'Further evaluation needed'
*/
define "Consider measles supplementary dose. Create a clinical note.":
input."Measles supplementary dose was NOT administered"
input."Measles supplementary dose was not administered"
and input."Measles routine immunization schedule is complete High Tx"
and input."No live vaccine was administered in the last four weeks"
and input."No live vaccine was administered in the last 4 weeks"
/*
@input: Consider measles supplementary dose. Create a clinical note. Guidance
@guidance: May vaccinate client for measles supplementary dose as supplementary dose was not administered, measles routine immunization schedule is complete and no live vaccine administered in the last 4 weeks. Check if one of the measles supplementary dose specific scenarios is applicable.
Expand Down
3 changes: 3 additions & 0 deletions input/fsh/codesystems/IMMZ.D.fsh
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ Description: "CodeSystem for IMMZ.D Data Elements"
* #DE26 "Expiration date" "The expiration date of the vaccine"
* #DE34 "Dose quantity " "The quantity of vaccine product that was administered"
* #DE35 "Health worker identifier" "The person, organization, or role of the entity that performed the act of giving the vaccine to the client. The implementing system can choose to populate this field using data from a health worker registry or health facility registry"
* #DE201 "Contact date" "The date and time of the client's contact"
* #DE202 "ANC contact number" "The ANC contact or visit number"
* #DE203 "Currently pregnant" "Client's pregnancy status"
* #DE86 "Client education and counselling on immunization" "Providing information, guidance, and support to client or caretakers (such as parents or legal guardians) regarding immunization practices"
* #DE87 "Counselling on functions of the immunological system" "Explaining to the client or caregiver how the vaccines work by triggering the body to produce an immune response"
* #DE88 "Advising about functions of the immunological system" "Explaining to the client or caregiver how the vaccines work by triggering the body to produce an immune response"
Expand Down
Loading

0 comments on commit 20d4904

Please sign in to comment.