<?xml version="1.0" encoding="UTF-8"?><library xmlns="urn:hl7-org:elm:r1" xmlns:a="urn:hl7-org:cql-annotations:r1" xmlns:fhir="http://hl7.org/fhir" xmlns:t="urn:hl7-org:elm-types:r1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" localId="0"><annotation signatureLevel="Overloads" translatorOptions="EnableAnnotations,EnableLocators,DisableListDemotion,DisableListPromotion" translatorVersion="4.9.0" xsi:type="a:CqlToElmInfo"/><annotation errorSeverity="warning" errorType="semantic" message="An operand identifier reference is hiding another identifier of the same name." xsi:type="a:CqlToElmError"/><annotation errorSeverity="warning" errorType="semantic" message="An operand identifier reference is hiding another identifier of the same name." xsi:type="a:CqlToElmError"/><annotation errorSeverity="warning" errorType="semantic" message="An operand identifier reference is hiding another identifier of the same name." xsi:type="a:CqlToElmError"/><annotation xsi:type="a:Annotation"><a:s r="296"><a:s>/*
 * Library: IMMZ.IND.37 Logic
 * Drop-out rate from the 1st dose of measles and rubella-containing vaccine to the 2nd dose
 * The percentage in the target population who received a 1st dose of measles and rubella-containing vaccine in the primary series but have not received the 2nd dose of measles and rubella-containing vaccine in the primary series (i.e. are past due for measles and rubella-containing vaccine 2nd dose) during the reporting period
 * 
 * Numerator: Number of clients who received a 1st dose of measles and rubella-containing vaccine during the reporting period who should have received the 2nd dose of measles and rubella-containing vaccine during the reporting period but did not receive it
 * Numerator Computation: (COUNT of clients with an immunization event WHERE "Vaccine type"" = "Measles and rubella-containing vaccines" for the 1st dose in the primary series AND "Date and time of vaccination" is during the reporting period) - (COUNT of clients with an immunization event WHERE "Vaccine type"" = "Measles and rubella-containing vaccines" for the 2nd dose in the primary series AND "Date and time of vaccination" is during the reporting period)
 * Denominator: Number of clients in the target population who received dose 1 of measles and rubella-containing vaccine during the reporting period
 * Denominator Computation: COUNT clients with an immunization event WHERE "Vaccine type" = "Measles and rubella-containing vaccines" for a 1st dose in the primary series AND "Date and time of vaccination" is during the reporting period
 * 
 * Disaggregation
 *  - Administrative area
 *  - Sex
 *  - Age in years
 *  - Age group (depending on schedule)
 *
 * References: WHO Immunization facility analysis guide (5)
 * 
 * Annotations: –
 */
library IMMZIND37Logic</a:s></a:s></annotation><identifier id="IMMZIND37Logic" system="http://smart.who.int/immunizations"/><schemaIdentifier id="urn:hl7-org:elm" version="r1"/><usings><def localId="1" localIdentifier="System" uri="urn:hl7-org:elm-types:r1" version="1.0.0"/><def localId="206" localIdentifier="FHIR" locator="23:1-23:26" uri="http://hl7.org/fhir" version="4.0.1"><annotation xsi:type="a:Annotation"><a:s r="206"><a:s>using </a:s><a:s><a:s>FHIR</a:s></a:s><a:s> version '4.0.1'</a:s></a:s></annotation></def></usings><includes><def localId="208" localIdentifier="FHIRHelpers" locator="25:1-25:35" path="http://hl7.org/fhir/FHIRHelpers" version="4.0.1"><annotation xsi:type="a:Annotation"><a:s r="208"><a:s>include </a:s><a:s><a:s>FHIRHelpers</a:s></a:s><a:s> version '4.0.1'</a:s></a:s></annotation></def><def localId="210" localIdentifier="WC" locator="27:1-27:27" path="http://smart.who.int/immunizations/WHOCommon"><annotation xsi:type="a:Annotation"><a:s r="210"><a:s>include </a:s><a:s><a:s>WHOCommon</a:s></a:s><a:s> called WC</a:s></a:s></annotation></def><def localId="212" localIdentifier="Common" locator="29:1-29:32" path="http://smart.who.int/immunizations/IMMZCommon"><annotation xsi:type="a:Annotation"><a:s r="212"><a:s>include </a:s><a:s><a:s>IMMZCommon</a:s></a:s><a:s> called Common</a:s></a:s></annotation></def><def localId="214" localIdentifier="Concepts" locator="30:1-30:36" path="http://smart.who.int/immunizations/IMMZConcepts"><annotation xsi:type="a:Annotation"><a:s r="214"><a:s>include </a:s><a:s><a:s>IMMZConcepts</a:s></a:s><a:s> called Concepts</a:s></a:s></annotation></def><def localId="216" localIdentifier="Elements" locator="31:1-31:45" path="http://smart.who.int/immunizations/IMMZIndicatorElements"><annotation xsi:type="a:Annotation"><a:s r="216"><a:s>include </a:s><a:s><a:s>IMMZIndicatorElements</a:s></a:s><a:s> called Elements</a:s></a:s></annotation></def></includes><parameters><def accessLevel="Public" localId="218" locator="34:1-34:88" name="Measurement Period"><annotation xsi:type="a:Annotation"><a:s r="218"><a:s>parameter "Measurement Period" </a:s><a:s r="230"><a:s>Interval&lt;</a:s><a:s r="231"><a:s>Date</a:s></a:s><a:s>&gt;</a:s></a:s><a:s> default </a:s><a:s r="229"><a:s r="223">Interval[@2025-01-01, @2025-12-31]</a:s></a:s></a:s></annotation><default highClosed="true" localId="229" locator="34:55-34:88" lowClosed="true" xsi:type="Interval"><low localId="223" locator="34:64-34:74" xsi:type="Date"><year localId="220" value="2025" valueType="t:Integer" xsi:type="Literal"/><month localId="221" value="1" valueType="t:Integer" xsi:type="Literal"/><day localId="222" value="1" valueType="t:Integer" xsi:type="Literal"/></low><high localId="228" locator="34:77-34:87" xsi:type="Date"><year localId="225" value="2025" valueType="t:Integer" xsi:type="Literal"/><month localId="226" value="12" valueType="t:Integer" xsi:type="Literal"/><day localId="227" value="31" valueType="t:Integer" xsi:type="Literal"/></high></default><parameterTypeSpecifier localId="230" locator="34:32-34:45" xsi:type="IntervalTypeSpecifier"><pointType localId="231" locator="34:41-34:44" name="t:Date" xsi:type="NamedTypeSpecifier"/></parameterTypeSpecifier></def></parameters><contexts><def localId="236" locator="36:1-36:15" name="Patient"/></contexts><statements><def context="Patient" localId="234" locator="36:1-36:15" name="Patient"><expression localId="235" xsi:type="SingletonFrom"><operand dataType="fhir:Patient" localId="233" locator="36:1-36:15" templateId="http://hl7.org/fhir/StructureDefinition/Patient" xsi:type="Retrieve"/></expression></def><def accessLevel="Public" context="Patient" localId="239" locator="41:1-42:6" name="Initial Population"><annotation xsi:type="a:Annotation"><a:s r="239"><a:s r="240">/*
 * As defined by Member State
 */
define "Initial Population":
  true</a:s></a:s></annotation><expression localId="240" locator="42:3-42:6" value="true" valueType="t:Boolean" xsi:type="Literal"/></def><def accessLevel="Public" context="Patient" localId="243" locator="49:1-51:65" name="Denominator"><annotation xsi:type="a:Annotation"><a:t name="denominator" value="Number of clients in the target population who received dose 1 of measles and rubella-containing vaccine during the reporting period"/><a:t name="pseudocode" value="&#34;Vaccine type&#34; = &#34;Measles and rubella-containing vaccines&#34; for a 1st dose in the primary series AND &#34;Date and time of vaccination&#34; is during the reporting period"/><a:t name="note" value="Updated to include those who have received the first dose and are due for the second during the measurement period"/><a:s r="243"><a:s>/*
@denominator: Number of clients in the target population who received dose 1 of measles and rubella-containing vaccine during the reporting period
@pseudocode: COUNT clients with an immunization event WHERE "Vaccine type" = "Measles and rubella-containing vaccines" for a 1st dose in the primary series AND "Date and time of vaccination" is during the reporting period
@note: Updated to include those who have received the first dose and are due for the second during the measurement period
*/
define "Denominator":
  </a:s><a:s r="244"><a:s r="245"><a:s>exists</a:s><a:s r="250"><a:s>( </a:s><a:s r="250"><a:s r="247"><a:s r="246"><a:s>Elements</a:s></a:s><a:s>.</a:s><a:s r="247"><a:s>"Measles and Rubella Doses Administered to Patient"</a:s></a:s></a:s><a:s>.</a:s><a:s r="250"><a:s>getDose(</a:s><a:s r="248"><a:s>'1'</a:s></a:s><a:s>)</a:s></a:s></a:s><a:s> )</a:s></a:s></a:s><a:s>
    and </a:s><a:s r="263"><a:s r="254"><a:s r="256"><a:s r="255"><a:s>Patient</a:s></a:s><a:s>.</a:s><a:s r="256"><a:s>birthDate</a:s></a:s></a:s><a:s> + </a:s><a:s r="257"><a:s>15 months</a:s></a:s></a:s><a:s r="263"> during </a:s><a:s r="261"><a:s>"Measurement Period"</a:s></a:s></a:s></a:s></a:s></annotation><expression localId="244" locator="50:3-51:65" xsi:type="And"><operand localId="245" locator="50:3-50:85" xsi:type="Exists"><operand libraryName="Common" localId="250" locator="50:9-50:85" name="getDose" xsi:type="FunctionRef"><signature localId="251" xsi:type="ListTypeSpecifier"><elementType localId="252" name="fhir:Immunization" xsi:type="NamedTypeSpecifier"/></signature><signature localId="253" name="t:String" xsi:type="NamedTypeSpecifier"/><operand libraryName="Elements" localId="247" locator="50:11-50:70" name="Measles and Rubella Doses Administered to Patient" xsi:type="ExpressionRef"/><operand localId="248" locator="50:80-50:82" value="1" valueType="t:String" xsi:type="Literal"/></operand></operand><operand localId="263" locator="51:9-51:65" xsi:type="In"><operand localId="254" locator="51:9-51:37" xsi:type="Add"><signature localId="259" name="t:Date" xsi:type="NamedTypeSpecifier"/><signature localId="260" name="t:Quantity" xsi:type="NamedTypeSpecifier"/><operand libraryName="FHIRHelpers" localId="258" name="ToDate" xsi:type="FunctionRef"><operand localId="256" locator="51:9-51:25" path="birthDate" xsi:type="Property"><source localId="255" locator="51:9-51:15" name="Patient" xsi:type="ExpressionRef"/></operand></operand><operand localId="257" locator="51:29-51:37" unit="months" value="15" xsi:type="Quantity"/></operand><operand localId="261" locator="51:46-51:65" name="Measurement Period" xsi:type="ParameterRef"/></operand></expression></def><def accessLevel="Public" context="Patient" localId="266" locator="59:1-61:119" name="Numerator"><annotation xsi:type="a:Annotation"><a:t name="numerator" value="Number of clients who received a 1st dose of measles and rubella-containing vaccine during the reporting period who should have received the 2nd dose of measles and rubella-containing vaccine during the reporting period but did not receive it"/><a:t name="pseudocode" value="&#34;Vaccine type&#34;&#34; = &#34;Measles and rubella-containing vaccines&#34; for the 1st dose in the primary series AND &#34;Date and time of vaccination&#34; is during the reporting period) - (COUNT of clients with an immunization event WHERE &#34;Vaccine type&#34;&#34; = &#34;Measles and rubella-containing vaccines&#34; for the 2nd dose in the primary series AND &#34;Date and time of vaccination&#34; is during the reporting period)"/><a:t name="note" value="Only include those from the denominator that did not receive a measles/rubella 2nd dose during the measurement period.&#xA;        Those where the 2nd dose due date is during the period but have not received the 2nd dose."/><a:s r="266"><a:s>/*
@numerator: Number of clients who received a 1st dose of measles and rubella-containing vaccine during the reporting period who should have received the 2nd dose of measles and rubella-containing vaccine during the reporting period but did not receive it
@pseudocode: (COUNT of clients with an immunization event WHERE "Vaccine type"" = "Measles and rubella-containing vaccines" for the 1st dose in the primary series AND "Date and time of vaccination" is during the reporting period) - (COUNT of clients with an immunization event WHERE "Vaccine type"" = "Measles and rubella-containing vaccines" for the 2nd dose in the primary series AND "Date and time of vaccination" is during the reporting period)
@note: Only include those from the denominator that did not receive a measles/rubella 2nd dose during the measurement period.
        Those where the 2nd dose due date is during the period but have not received the 2nd dose.
*/
define "Numerator":
  </a:s><a:s r="267"><a:s r="268"><a:s>"Denominator"</a:s></a:s><a:s>
  and </a:s><a:s r="269"><a:s>not </a:s><a:s r="270"><a:s>exists</a:s><a:s r="275"><a:s>( </a:s><a:s r="275"><a:s r="272"><a:s r="271"><a:s>Elements</a:s></a:s><a:s>.</a:s><a:s r="272"><a:s>"Measles and Rubella Doses Administered to Patient During Measurement Period"</a:s></a:s></a:s><a:s>.</a:s><a:s r="275"><a:s>getDose(</a:s><a:s r="273"><a:s>'2'</a:s></a:s><a:s>)</a:s></a:s></a:s><a:s> )</a:s></a:s></a:s></a:s></a:s></a:s></annotation><expression localId="267" locator="60:3-61:119" xsi:type="And"><operand localId="268" locator="60:3-60:15" name="Denominator" xsi:type="ExpressionRef"/><operand localId="269" locator="61:7-61:119" xsi:type="Not"><operand localId="270" locator="61:11-61:119" xsi:type="Exists"><operand libraryName="Common" localId="275" locator="61:17-61:119" name="getDose" xsi:type="FunctionRef"><signature localId="276" xsi:type="ListTypeSpecifier"><elementType localId="277" name="fhir:Immunization" xsi:type="NamedTypeSpecifier"/></signature><signature localId="278" name="t:String" xsi:type="NamedTypeSpecifier"/><operand libraryName="Elements" localId="272" locator="61:19-61:104" name="Measles and Rubella Doses Administered to Patient During Measurement Period" xsi:type="ExpressionRef"/><operand localId="273" locator="61:114-61:116" value="2" valueType="t:String" xsi:type="Literal"/></operand></operand></operand></expression></def><def accessLevel="Public" context="Patient" localId="281" locator="69:1-70:43" name="Stratification 1"><annotation xsi:type="a:Annotation"><a:t name="disaggregation" value="Administrative area&#xA;                 Sex&#xA;                 Age in years&#xA;                 Age group (depending on schedule)"/><a:s r="281"><a:s>/*
@disaggregation: Administrative area
                 Sex
                 Age in years
                 Age group (depending on schedule)
*/
define "Stratification 1":
	</a:s><a:s r="283"><a:s r="282"><a:s>Elements</a:s></a:s><a:s>.</a:s><a:s r="283"><a:s>"By Geographic Region Stratifier"</a:s></a:s></a:s></a:s></annotation><expression libraryName="Elements" localId="283" locator="70:2-70:43" name="By Geographic Region Stratifier" xsi:type="ExpressionRef"/></def><def accessLevel="Public" context="Patient" localId="286" locator="72:1-73:47" name="Stratification 2"><annotation xsi:type="a:Annotation"><a:s r="286"><a:s>define "Stratification 2":
	</a:s><a:s r="288"><a:s r="287"><a:s>Elements</a:s></a:s><a:s>.</a:s><a:s r="288"><a:s>"By Administrative Gender Stratifier"</a:s></a:s></a:s></a:s></annotation><expression libraryName="Elements" localId="288" locator="73:2-73:47" name="By Administrative Gender Stratifier" xsi:type="ExpressionRef"/></def><def accessLevel="Public" context="Patient" localId="291" locator="75:1-76:26" name="Stratification 3"><annotation xsi:type="a:Annotation"><a:s r="291"><a:s>define "Stratification 3":
	</a:s><a:s r="293"><a:s r="292"><a:s>Elements</a:s></a:s><a:s>.</a:s><a:s r="293"><a:s>"Age Stratifier"</a:s></a:s></a:s></a:s></annotation><expression libraryName="Elements" localId="293" locator="76:2-76:26" name="Age Stratifier" xsi:type="ExpressionRef"/></def><def accessLevel="Public" context="Patient" localId="296" locator="78:1-79:37" name="Stratification 4"><annotation xsi:type="a:Annotation"><a:s r="296"><a:s>define "Stratification 4":
	</a:s><a:s r="298"><a:s r="297"><a:s>Elements</a:s></a:s><a:s>.</a:s><a:s r="298"><a:s>"Toddler By Age Stratifier"</a:s></a:s></a:s></a:s></annotation><expression libraryName="Elements" localId="298" locator="79:2-79:37" name="Toddler By Age Stratifier" xsi:type="ExpressionRef"/></def></statements></library>