Quality Measure Implementation Guide
1.0.0 - STU 1 International flag

Quality Measure Implementation Guide, published by HL7 International / Clinical Quality Information. This guide is not an authorized publication; it is the continuous build for version 1.0.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/HL7/fhir-cqm/ and changes regularly. See the Directory of published versions

: EXM108 - Venous Thromboembolism Prophylaxis - XML Representation

Page standards status: Informative

Raw xml | Download


<Measure xmlns="http://hl7.org/fhir">
  <id value="EXM108-FHIR"/>
  <meta>
    <profile
             value="http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-shareablemeasure"/>
    <profile
             value="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-computablemeasure"/>
    <profile
             value="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-proportionmeasure"/>
    <profile
             value="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-cqlmeasure"/>
    <profile
             value="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-computablemeasure"/>
  </meta>
  <text>
    <status value="extensions"/>
    <div xmlns="http://www.w3.org/1999/xhtml">
  <table class="narrative-table">
    <tbody>
<tr>


<th colspan="2" scope="row" class="row-header">Metadata</th>


</tr>

<tr>


<th scope="row" class="row-header">Title</th>


<td class="content-container">EXM108 - Venous Thromboembolism Prophylaxis</td>
</tr>



<tr>


<th scope="row" class="row-header">Version</th>


<td class="content-container">8.2.000</td>
</tr>







  
<tr>


<th scope="row" class="row-header">Identifier</th>


<td class="content-container">108</td>
</tr>


  
<tr>


<th scope="row" class="row-header">Identifier</th>


<td class="content-container">urn:oid:2.16.840.1.113883.4.642.40.61.29.3</td>
</tr>



  
    
    
<tr>


<th scope="row" class="row-header">Effective Period</th>


<td class="content-container">2018-01-01 through 2018-12-31</td>
</tr>

  


<tr>


<th scope="row" class="row-header">Approval Date</th>


<td class="content-container">2019-03-08</td>
</tr>


<tr>


<th scope="row" class="row-header">Last Review Date</th>


<td class="content-container">2019-03-08</td>
</tr>




<tr>


<th scope="row" class="row-header">Experimental</th>


<td class="content-container">true</td>
</tr>




<tr>


<th scope="row" class="row-header">Use Context</th>


<td class="content-container"><span title="{http://terminology.hl7.org/CodeSystem/usage-context-type venue}">Clinical Venue</span> = <span title="Codes:{http://hl7.org/fhir/uv/cqm/CodeSystem/intended-venue-codes eh}">EH</span></td>
</tr>


<tr>


<th scope="row" class="row-header">Jurisdiction</th>


<td class="content-container"><span title="Codes:{http://unstats.un.org/unsd/methods/m49/m49.htm 001}">Global (Whole world)</span></td>
</tr>


<tr>


<th scope="row" class="row-header">Topic</th>


<td class="content-container"><span title="Codes:{http://loinc.org 57024-2}">Health Quality Measure Document</span></td>
</tr>







<tr>


<th scope="row" class="row-header">Steward (Publisher)</th>


<td class="content-container">HL7 International / Clinical Quality Information</td>
</tr>









<tr>


<th scope="row" class="row-header">Description</th>


<td class="content-container"><div><p>This measure assesses the number of patients who received VTE prophylaxis or have documentation why no VTE prophylaxis was given the day of or the day after hospital admission or surgery end date for surgeries that start the day of or the day after hospital admission</p>
</div></td>
</tr>



<tr>


<th scope="row" class="row-header">Copyright</th>


<td class="content-container"><div><p>Measure specifications are in the Public Domain.</p>
<p>LOINC(R) is a registered trademark of the Regenstrief Institute.</p>
<p>This material contains SNOMED Clinical Terms(R) (SNOMED CT(C)) copyright 2004-2017 International Health Terminology Standards Development Organization. All rights reserved.</p>
</div></td>
</tr>


<tr>


<th scope="row" class="row-header">Disclaimer</th>


<td class="content-container"><div><p>These performance measures are not clinical guidelines and do not establish a standard of medical care, and have not been tested for all potential applications. The measures and specifications are provided without warranty</p>
</div></td>
</tr>



  
<tr>


<th scope="row" class="row-header">Measure Basis</th>


<td class="content-container">Encounter</td>
</tr>



<tr>


<th scope="row" class="row-header">Measure Scoring</th>


<td class="content-container"><span title="Codes:{http://terminology.hl7.org/CodeSystem/measure-scoring proportion}">Proportion</span></td>
</tr>





<tr>


<th scope="row" class="row-header">Measure Type</th>


<td class="content-container"><span title="Codes:{http://terminology.hl7.org/CodeSystem/measure-type process}">Process</span></td>
</tr>




<tr>


<th scope="row" class="row-header">Rationale</th>


<td class="content-container"><div><p>Hospitalized patients at high-risk for VTE may develop an asymptomatic deep vein thrombosis (DVT), and die from pulmonary embolism (PE) even before the diagnosis is suspected. The majority of fatal events occur as sudden or abrupt death, underscoring the importance of prevention as the most critical action step for reducing death from PE (Geerts, et al, 2008).</p>
<p>The estimated annual incidence of deep-vein thrombosis (DVT) and pulmonary embolism (PE), known collectively as venous thromboembolism (VTE), is approximately 900,000 (Geerts, et al, 2008). Approximately two-thirds of cases of DVT or PE are associated with recent hospitalization. This is consistent with the 2001 report by The Agency for Healthcare Research and Quality (AHRQ). AHRQ indicates that &quot;the appropriate application of effective preventive measures in hospitals has major potential for improving patient safety by reducing the incidence of venous thromboembolism&quot; (Shojania, 2001).</p>
<p>Despite its proven effectiveness, rates of appropriate thromboprophylaxis remain low in both medical and surgical patients. A recent analysis from the ENDORSE survey, which evaluated prophylaxis rates in 17,084 major surgery patients, found that more than one third of patients at risk for VTE (38%) did not receive prophylaxis and that rates varied by surgery type (Cohen, et al., 2008).</p>
<p>In a review of evidence-based patient safety practices, the Agency for Healthcare Research and Quality defined thromboprophylaxis against VTE as the &quot;number one patient safety practice&quot; for hospitalized patients (Shojania, 2001). Updated &quot;safe practices&quot; published by the National Quality Forum (NQF) recommend routine evaluation of hospitalized patients for risk of VTE and use of appropriate prophylaxis (National Quality Forum. National Voluntary Consensus Standards for Prevention and Care of Venous Thromboembolism, 2006).</p>
<p>As noted by the ACCP, a vast number of randomized clinical trials provide irrefutable evidence that thromboprophylaxis reduces VTE events, and there are studies that have also shown that fatal PE is prevented by thromboprophylaxis (Geerts, et al. 2008).</p>
<p>Some select surgeries have previously been monitored in the Surgical Care Improvement Project; since performance on these surgeries has achieved very high levels, they are not included in this measure.</p>
</div></td>
</tr>


<tr>


<th scope="row" class="row-header">Clinical Recommendation Statement</th>


<td class="content-container"><div><p>Failure to recognize and protect patients at risk for venous thromboembolism (VTE) increases the chances for acutely ill hospitalized patients at high risk for developing a deep vein thrombosis or dying from a pulmonary emboli. Screening all patients is the only evidence based practice in reducing incidence of disease.  All hospitalized patients should be evaluated for primary VTE prophylaxis, and given appropriate prophylaxis when indicated.</p>
</div></td>
</tr>


<tr>


<th scope="row" class="row-header">Improvement Notation</th>


<td class="content-container"><span title="Codes:{http://terminology.hl7.org/CodeSystem/measure-improvement-notation increase}">Increased score indicates improvement</span></td>
</tr>









  
  
  
    
    <tr>


<th colspan="2" scope="row" class="row-header">Measure Group (Rate) (ID: primary)</th>


</tr>
  
  
  









  
  
    
    
    <tr>
      
        

<th scope="row" class="row-header">Initial Population</th>


      
      <td class="content-container">
        
        <em>ID</em>: primary-exm108-initial-population
        <br/>
        
        
          <em>Description</em>:
          <p style="white-space: pre-line" class="tab-one">Patients age 18 and older discharged from hospital inpatient acute care without a diagnosis of venous thromboembolism (VTE) or obstetrics with a length of stay less than or equal to 120 days that ends during the measurement period</p>
        
        
          
            
              
              <em>Criteria</em>: <a href="#primary-primary-exm108-initial-population">Initial Population</a> 
            
          
          
        
        
        
      </td>
    </tr>
  

  
    
    
    <tr>
      
        

<th scope="row" class="row-header">Numerator</th>


      
      <td class="content-container">
        
        <em>ID</em>: primary-exm108-numerator
        <br/>
        
        
          <em>Description</em>:
          <p style="white-space: pre-line" class="tab-one">Patients who received VTE prophylaxis:
- the day of or the day after hospital admission
- the day of or the day after surgery end date for surgeries that end the day of or the day after hospital admission

Patients who have documentation of a reason why no VTE prophylaxis was given:
- between arrival and hospital admission
- the day of or the day after hospital admission
- the day of or the day after surgery end date (for surgeries that end the day of or the day after hospital admission)</p>
        
        
          
            
              
              <em>Criteria</em>: <a href="#primary-primary-exm108-numerator">Numerator</a> 
            
          
          
        
        
        
      </td>
    </tr>
  

  
    
    
    <tr>
      
        

<th scope="row" class="row-header">Denominator</th>


      
      <td class="content-container">
        
        <em>ID</em>: primary-exm108-denominator
        <br/>
        
        
          <em>Description</em>:
          <p style="white-space: pre-line" class="tab-one">All patients in the initial population</p>
        
        
          
            
              
              <em>Criteria</em>: <a href="#primary-primary-exm108-denominator">Denominator</a> 
            
          
          
        
        
        
      </td>
    </tr>
  

  
    
    
    <tr>
      
        

<th scope="row" class="row-header">Denominator Exclusion</th>


      
      <td class="content-container">
        
        <em>ID</em>: primary-exm108-denominator-exclusion
        <br/>
        
        
          <em>Description</em>:
          <p style="white-space: pre-line" class="tab-one">* Patients who have a length of stay less than 2 days
* Patients with comfort measures documented anytime between arrival and the day after hospital admission
* Patients with comfort measures documented by the day after surgery end date for surgeries that start the day of or the day after hospital admission
* Patients who are direct admits to intensive care unit (ICU), or transferred to ICU the day of or the day after hospital admission with ICU length of stay greater than or equal to one day
* Patients with a principal diagnosis of mental disorders or stroke
* Patients with a principal procedure of Surgical Care Improvement Project (SCIP) VTE selected surgeries</p>
        
        
          
            
              
              <em>Criteria</em>: <a href="#primary-primary-exm108-denominator-exclusion">Denominator Exclusion</a> 
            
          
          
        
        
        
      </td>
    </tr>
  

  



  <tr>


<th colspan="2" scope="row" class="row-header">Supplemental Data Elements</th>


</tr>


<tr>
  

<th scope="row" class="row-header">Supplemental Data Element</th>


  <td class="content-container">
    
    
      
        
          <em>Usage Code</em>: <span title="Codes:{http://terminology.hl7.org/CodeSystem/measure-data-usage supplemental-data}">Supplemental Data</span>
        
        <br/>
      
    
    
      <em>Description</em>: No description provided
    
    
      
        <br/>
        
          
          <em>Logic Definition</em>: <a href="#exm108-sde-ethnicity">SDE Ethnicity</a> 
        
      
    
  </td>
</tr>

<tr>
  

<th scope="row" class="row-header">Supplemental Data Element</th>


  <td class="content-container">
    
    
      
        
          <em>Usage Code</em>: <span title="Codes:{http://terminology.hl7.org/CodeSystem/measure-data-usage supplemental-data}">Supplemental Data</span>
        
        <br/>
      
    
    
      <em>Description</em>: No description provided
    
    
      
        <br/>
        
          
          <em>Logic Definition</em>: <a href="#exm108-sde-payer">SDE Payer</a> 
        
      
    
  </td>
</tr>

<tr>
  

<th scope="row" class="row-header">Supplemental Data Element</th>


  <td class="content-container">
    
    
      
        
          <em>Usage Code</em>: <span title="Codes:{http://terminology.hl7.org/CodeSystem/measure-data-usage supplemental-data}">Supplemental Data</span>
        
        <br/>
      
    
    
      <em>Description</em>: No description provided
    
    
      
        <br/>
        
          
          <em>Logic Definition</em>: <a href="#exm108-sde-race">SDE Race</a> 
        
      
    
  </td>
</tr>

<tr>
  

<th scope="row" class="row-header">Supplemental Data Element</th>


  <td class="content-container">
    
    
      
        
          <em>Usage Code</em>: <span title="Codes:{http://terminology.hl7.org/CodeSystem/measure-data-usage supplemental-data}">Supplemental Data</span>
        
        <br/>
      
    
    
      <em>Description</em>: No description provided
    
    
      
        <br/>
        
          
          <em>Logic Definition</em>: <a href="#exm108-sde-sex">SDE Sex</a> 
        
      
    
  </td>
</tr>


<tr>


<th colspan="2" scope="row" class="row-header">Measure Logic</th>


</tr>

<tr>


<th scope="row" class="row-header">Primary Library</th>


<td class="content-container"><a href="Library-EXM108.html">EXM108 - Venous Thromboembolism Prophylaxis Library</a></td>
</tr>




<tr>
  <th scope="row" class="row-header">Contents</th>
  <td class="content-container">
    <em><a href="#population-criteria">Population Criteria</a></em>
    <br/>
    <em><a href="#definitions">Logic Definitions</a></em>
    <br/>
    <em><a href="#terminology">Terminology</a></em>
    <br/>
    <em><a href="#dependencies">Dependencies</a></em>
    <br/>
    <em><a href="#data-requirements">Data Requirements</a></em>
    <br/>
  </td>
</tr>


  <tr>


<th colspan="2" scope="row" class="row-header"><a name="population-criteria"> </a>Population Criteria</th>


</tr>
  
  
  

  
  
  
    
    <tr>


<th colspan="2" scope="row" class="row-header">Measure Group (Rate) (ID: primary)</th>


</tr>
  
  
  
  
    
      
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
            
              
            
            
            
            <tr>
  <th scope="row" rowspan="2" class="row-header">
    
    Initial Population
    
  </th>
</tr>
<tr>

  <td>
    
    
    
    
      
      <a name="primary-primary-exm108-initial-population"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Initial Population&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot;</code></pre>
    
      
      <a href="#exm108-initial-population"><em>Definition</em></a>
    
  </td>

</tr>

          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
      
    
  

  
    
      
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
            
              
            
            
            
            <tr>
  <th scope="row" rowspan="2" class="row-header">
    
    Numerator
    
  </th>
</tr>
<tr>

  <td>
    
    
    
    
      
      <a name="primary-primary-exm108-numerator"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Numerator&quot;:
  &quot;Encounter With VTE Prophylaxis Received on Day of or Day After Admission or Procedure&quot;
    union ( &quot;Encounter With Medication Oral Factor Xa Inhibitor Administered on Day of or Day After Admission or Procedure&quot;
    			  intersect ( &quot;Encounter With Prior or Present Diagnosis of Atrial Fibrillation or VTE&quot;
    						    union &quot;Encounter With Prior or Present Procedure of Hip or Knee Replacement Surgery&quot;
    			            )
          )
    union &quot;Encounter With Low Risk for VTE or Anticoagulant Administered&quot;
    union &quot;Encounter With No VTE Prophylaxis Due to Medical Reason&quot;
    union &quot;Encounter With No VTE Prophylaxis Due to Patient Refusal&quot;</code></pre>
    
      
      <a href="#exm108-numerator"><em>Definition</em></a>
    
  </td>

</tr>

          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
      
    
  

  
    
      
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
            
              
            
            
            
            <tr>
  <th scope="row" rowspan="2" class="row-header">
    
    Denominator
    
  </th>
</tr>
<tr>

  <td>
    
    
    
    
      
      <a name="primary-primary-exm108-denominator"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Denominator&quot;:
      &quot;Initial Population&quot;</code></pre>
    
      
      <a href="#exm108-denominator"><em>Definition</em></a>
    
  </td>

</tr>

          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
      
    
  

  
    
      
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
            
              
            
            
            
            <tr>
  <th scope="row" rowspan="2" class="row-header">
    
    Denominator Exclusion
    
  </th>
</tr>
<tr>

  <td>
    
    
    
    
      
      <a name="primary-primary-exm108-denominator-exclusion"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Denominator Exclusion&quot;:
  &quot;Encounter Less Than 2 Days&quot;
     union &quot;Encounter With ICU Location Stay 1 Day or More&quot;
     union &quot;Encounter With Principal Diagnosis of Mental Disorder or Stroke&quot;
     union &quot;Encounter With Principal Procedure of SCIP VTE Selected Surgery&quot;
     union &quot;Encounter With Intervention Comfort Measures From Day of Start of Hospitalization To Day After Admission&quot;
     union &quot;Encounter With Intervention Comfort Measures on Day of or Day After Procedure&quot;</code></pre>
    
      
      <a href="#exm108-denominator-exclusion"><em>Definition</em></a>
    
  </td>

</tr>

          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
          
        
      
    
  

  
  

  
  


  <tr>


<th colspan="2" scope="row" class="row-header"><a name="definitions"> </a>Logic Definitions</th>


</tr>
  
  
          
        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> SupplementalDataElements</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="supplementaldataelements-sde-sex"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SDE Sex&quot;:
  case
      when Patient.gender = 'male' then Code { code: 'M', system: 'http://hl7.org/fhir/v3/AdministrativeGender', display: 'Male' }
      when Patient.gender = 'female' then Code { code: 'F', system: 'http://hl7.org/fhir/v3/AdministrativeGender', display: 'Female' }
      else null
    end</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> SupplementalDataElements</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="supplementaldataelements-sde-payer"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SDE Payer&quot;:
  [Coverage: type in &quot;Payer&quot;] Payer
        return {
          code: Payer.type,
          period: Payer.period
        }</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> SupplementalDataElements</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="supplementaldataelements-sde-ethnicity"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SDE Ethnicity&quot;:
  (flatten (
      Patient.extension Extension
        where Extension.url = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity'
          return Extension.extension
    )) E
      where E.url = 'ombCategory'
        or E.url = 'detailed'
      return E.value as Coding</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> SupplementalDataElements</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="supplementaldataelements-sde-race"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SDE Race&quot;:
  (flatten (
      Patient.extension Extension
        where Extension.url = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-race'
          return Extension.extension
    )) E
      where E.url = 'ombCategory'
        or E.url = 'detailed'
      return E.value as Coding</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        




        
        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> TJCOverall</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="tjcoverall-calendardayofordayafter"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;CalendarDayOfOrDayAfter&quot;(StartValue DateTime ):
	Interval(Global.&quot;ToDate&quot;(StartValue), Global.&quot;ToDate&quot;(StartValue + 2 days))</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        




        
        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> VTEICU</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="vteicu-fromdayofstartofhospitalizationtodayafteradmission"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(Encounter FHIR.Encounter ):
	Interval[Global.&quot;ToDate&quot;(start of Global.&quot;HospitalizationWithObservation&quot;(Encounter)), Global.&quot;ToDate&quot;(start of Encounter.period + 2 days))</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        




        
        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-sde-sex"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SDE Sex&quot;:
	SDE.&quot;SDE Sex&quot;</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-admission-without-vte-or-obstetrical-conditions"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Admission Without VTE or Obstetrical Conditions&quot;:
  Global.&quot;Inpatient Encounter&quot; InpatientEncounter
    where not exists (
      (Global.EncounterDiagnosis(InpatientEncounter)) EncounterDiagnosis
        where EncounterDiagnosis.code in &quot;Obstetrics&quot;
          or EncounterDiagnosis.code in &quot;Venous Thromboembolism&quot;
          or EncounterDiagnosis.code in &quot;Obstetrics VTE&quot;
    )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-age-range-and-without-vte-diagnosis-or-obstetrical-conditions"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">// Note: added FHIRHelpers.ToDate() in R4
define &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot;:
  ( Global.&quot;Inpatient Encounter&quot; InpatientEncounter
        where Global.&quot;CalendarAgeInYearsAt&quot;(FHIRHelpers.ToDate(Patient.birthDate), start of InpatientEncounter.period) &gt;= 18
  )
    intersect &quot;Admission Without VTE or Obstetrical Conditions&quot;</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-vte-prophylaxis-by-medication-administered-or-device-applied"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">// 10/29: Replaced DeviceUseStatement with Procedure with a new value set and procedure.usdCode for specifying devices
define &quot;VTE Prophylaxis by Medication Administered or Device Applied&quot;:
  ( [&quot;MedicationAdministration&quot;: medication in &quot;Low Dose Unfractionated Heparin for VTE Prophylaxis&quot;] VTEMedication
      where VTEMedication.status ='completed'
			     and VTEMedication.dosage.route in &quot;Subcutaneous route&quot;
  )
   union ([&quot;MedicationAdministration&quot;: medication in &quot;Low Molecular Weight Heparin for VTE Prophylaxis&quot;] LMWH where LMWH.status = 'completed')
    union ([&quot;MedicationAdministration&quot;: medication in &quot;Injectable Factor Xa Inhibitor for VTE Prophylaxis&quot;] FactorXa where FactorXa.status = 'completed')
     union ([&quot;MedicationAdministration&quot;: medication in &quot;Warfarin&quot;] Warfarin where Warfarin.status = 'completed')
      union (
          [&quot;Procedure&quot;: &quot;Device Application&quot;] DeviceApplied
          where DeviceApplied.status = 'complete'
                and (DeviceApplied.usedCode in &quot;Intermittent pneumatic compression devices (IPC)&quot;
                    or DeviceApplied.usedCode in&quot;Venous foot pumps (VFP)&quot;
                    or DeviceApplied.usedCode in &quot;Graduated compression stockings (GCS)&quot;
                    )
          )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-vte-prophylaxis-received-on-day-of-or-day-after-admission-or-procedure"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With VTE Prophylaxis Received on Day of or Day After Admission or Procedure&quot;:
 	( from
      &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
      &quot;VTE Prophylaxis by Medication Administered or Device Applied&quot; VTEProphylaxis
    where Coalesce(Global.&quot;Normalize Interval&quot;(VTEProphylaxis.effective), Global.&quot;Normalize Interval&quot;(VTEProphylaxis.performed)) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(start of QualifyingEncounter.period)
    return QualifyingEncounter
 	)
 	union (
    from
      &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
      [&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
      &quot;VTE Prophylaxis by Medication Administered or Device Applied&quot; VTEProphylaxis
    where Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
      and Coalesce(Global.&quot;Normalize Interval&quot;(VTEProphylaxis.effective), Global.&quot;Normalize Interval&quot;(VTEProphylaxis.performed)) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
    return QualifyingEncounter
	)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-medication-oral-factor-xa-inhibitor-administered-on-day-of-or-day-after-admission-or-procedure"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With Medication Oral Factor Xa Inhibitor Administered on Day of or Day After Admission or Procedure&quot;:
	( from
    		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
  			[&quot;MedicationAdministration&quot;: medication in &quot;Oral Factor Xa Inhibitor for VTE Prophylaxis or VTE Treatment&quot;] FactorXaMedication
    where FactorXaMedication.status = 'completed'
      and Global.&quot;Normalize Interval&quot;(FactorXaMedication.effective) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(start of QualifyingEncounter.period)
    return QualifyingEncounter
    )
    union ( from
    				  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
      				[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
      				[&quot;MedicationAdministration&quot;: medication in &quot;Oral Factor Xa Inhibitor for VTE Prophylaxis or VTE Treatment&quot;] FactorXaMedication
      			where FactorXaMedication.status = 'completed'
                and AnesthesiaProcedure.status = 'completed'
      			    and Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
      					and Global.&quot;Normalize Interval&quot;(FactorXaMedication.effective) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
      			return QualifyingEncounter
      		)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-prior-or-present-diagnosis-of-atrial-fibrillation-or-vte"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With Prior or Present Diagnosis of Atrial Fibrillation or VTE&quot;:
	( &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
		with [&quot;Condition&quot;: code in &quot;Atrial Fibrillation/Flutter&quot;] AtrialFibrillation
		such that FHIRHelpers.ToConcept(AtrialFibrillation.clinicalStatus) in { Global.&quot;active&quot;, Global.&quot;recurrence&quot;, Global.&quot;relapse&quot; }
			and Global.&quot;Normalize Interval&quot;(AtrialFibrillation.onset) starts on or before end of QualifyingEncounter.period
    )
    union ( &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    				where Global.EncounterDiagnosis(QualifyingEncounter).code in &quot;Atrial Fibrillation/Flutter&quot;
    			)
    union ( &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    				with [&quot;Condition&quot;: code in &quot;Venous Thromboembolism&quot;] VTEDiagnosis
    				such that  FHIRHelpers.ToConcept(VTEDiagnosis.clinicalStatus) in { Global.&quot;inactive&quot;, Global.&quot;remission&quot;, Global.&quot;resolved&quot; }
      					//and VTEDiagnosis.verificationStatus = 'confirmed'
    				and Global.&quot;Normalize Interval&quot;(VTEDiagnosis.onset) before start of QualifyingEncounter.period
      		)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-prior-or-present-procedure-of-hip-or-knee-replacement-surgery"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With Prior or Present Procedure of Hip or Knee Replacement Surgery&quot;:
	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
	with ( [&quot;Procedure&quot;: &quot;Hip Replacement Surgery&quot;]
    			union [&quot;Procedure&quot;: &quot;Knee Replacement Surgery&quot;] ) HipKneeProcedure
	such that HipKneeProcedure.status = 'completed'
	     and Global.&quot;Normalize Interval&quot;(HipKneeProcedure.performed) starts on or before end of QualifyingEncounter.period</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-is-in-low-risk-for-vte-or-on-anticoagulant"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Is In Low Risk for VTE or On Anticoagulant&quot;:
	  ( [&quot;Observation&quot;: &quot;Risk for venous thromboembolism&quot;] VTERiskAssessment
			  where VTERiskAssessment.value in &quot;Low Risk&quot;
        and VTERiskAssessment.status in {'final','amended', 'corrected'}
	  )
  union ( [&quot;Observation&quot;: &quot;INR&quot;] INRLabTest
        where INRLabTest.value as Quantity &gt; 3.0
            and INRLabTest.status in {'final','amended', 'corrected'}
        return &quot;Observation&quot; { id: INRLabTest.id, effective: INRLabTest.issued }
        )
  union ((( [&quot;MedicationAdministration&quot;: &quot;Unfractionated Heparin&quot;] UnfractionatedHeparin
          where UnfractionatedHeparin.dosage.route in &quot;Intravenous route&quot;
         )
         union [&quot;MedicationAdministration&quot;: &quot;Direct Thrombin Inhibitor&quot;]
         union [&quot;MedicationAdministration&quot;: &quot;Glycoprotein IIb/IIIa Inhibitors&quot;] ) AnticoagulantMedication
         where AnticoagulantMedication.status = 'complete'
         return &quot;Observation&quot; { id: AnticoagulantMedication.id, effective: AnticoagulantMedication.effective }
      )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-low-risk-for-vte-or-anticoagulant-administered-from-day-of-start-of-hospitalization-to-day-after-admission"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Low Risk for VTE or Anticoagulant Administered From Day of Start of Hospitalization To Day After Admission&quot;:
 	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    with &quot;Is In Low Risk for VTE or On Anticoagulant&quot; VTERiskAssessment
    such that Global.&quot;Normalize Interval&quot;(VTERiskAssessment.effective) starts during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-low-risk-for-vte-or-anticoagulant-administered-on-day-of-or-day-after-procedure"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Low Risk for VTE or Anticoagulant Administered on Day of or Day After Procedure&quot;:
 	from
   		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
   		[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
   		&quot;Is In Low Risk for VTE or On Anticoagulant&quot; VTERiskAssessment
	where Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
 			and Global.&quot;Normalize Interval&quot;(VTERiskAssessment.effective) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
	return QualifyingEncounter</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-low-risk-for-vte-or-anticoagulant-administered"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With Low Risk for VTE or Anticoagulant Administered&quot;:
   &quot;Low Risk for VTE or Anticoagulant Administered From Day of Start of Hospitalization To Day After Admission&quot;
   	 union &quot;Low Risk for VTE or Anticoagulant Administered on Day of or Day After Procedure&quot;</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-medication-administered-or-ordered"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Medication Administered or Ordered&quot;:
   ((	[&quot;MedicationAdministration&quot;: medication in &quot;Low Dose Unfractionated Heparin for VTE Prophylaxis&quot;]
     union
	    [&quot;MedicationAdministration&quot;: medication in &quot;Low Molecular Weight Heparin for VTE Prophylaxis&quot;]
     union
	    [&quot;MedicationAdministration&quot;: medication in &quot;Injectable Factor Xa Inhibitor for VTE Prophylaxis&quot;]
     union
	    [&quot;MedicationAdministration&quot;: medication in &quot;Warfarin&quot;]
       ) MedicationAdm
       where MedicationAdm.status = 'not-done'
        )
  union
	   ((	[&quot;MedicationRequest&quot;: medication in &quot;Low Dose Unfractionated Heparin for VTE Prophylaxis&quot;]
  	union
  	 [&quot;MedicationRequest&quot;: medication in &quot;Low Molecular Weight Heparin for VTE Prophylaxis&quot;]
    union
    	[&quot;MedicationRequest&quot;: medication in &quot;Injectable Factor Xa Inhibitor for VTE Prophylaxis&quot;]
    union
    	[&quot;MedicationRequest&quot;: medication in &quot;Warfarin&quot;]
    ) MedicationOrder
    	where	MedicationOrder.doNotPerform is true
        and MedicationOrder.status in {'completed', 'cancelled'}
        //11/5 discussion: all expressions for QI-Core must include a status.
        //Therefore, we need ServiceRequest.status = completed; and MedicationRequest.status = cancelled (or completed, since cancelled indicates it was once ordered but intentionally never filled).
        //So the not done issue is handled by ServiceRequest.doNotPerform = True  Or MedicationRequest.doNotPerform = True
    )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-medication-due-to-medical-reason-from-day-of-start-of-hospitalization-to-day-after-admission"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Medication Due to Medical Reason From Day of Start of Hospitalization To Day After Admission&quot;:
   	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
       with	&quot;No VTE Prophylaxis Medication Administered or Ordered&quot; NoVTEMedication
     	such that Coalesce(NoVTEMedication.statusReason,NoVTEMedication.reasonCode) in &quot;Medical Reason&quot;
      			and Coalesce(NoVTEMedication.authoredOn, start of Global.&quot;Normalize Interval&quot;(NoVTEMedication.effective)) during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-device-applied-or-ordered"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Device Applied or Ordered&quot;:
  ((
    [&quot;ServiceRequest&quot;: &quot;Venous foot pumps (VFP)&quot;]
    union [&quot;ServiceRequest&quot;: &quot;Intermittent pneumatic compression devices (IPC)&quot;]
    union [&quot;ServiceRequest&quot;: &quot;Graduated compression stockings (GCS)&quot;]
    ) DeviceOrder
    where DeviceOrder.status = 'completed'
        and DeviceOrder.doNotPerform is true
    return {id: DeviceOrder.id, requestStatusReason: GetStatusReason(DeviceOrder), authoredOn: DeviceOrder.authoredOn}
    )
  union
    (
      [&quot;Procedure&quot;: &quot;Device Application&quot;] DeviceApplied
      let DeviceNotDoneTiming: Global.GetExtension(DeviceApplied, 'qicore-recorded').value
      where (DeviceApplied.usedCode in &quot;Intermittent pneumatic compression devices (IPC)&quot;
            or DeviceApplied.usedCode in &quot;Venous foot pumps (VFP)&quot;
            or DeviceApplied.usedCode in &quot;Graduated compression stockings (GCS)&quot;
            )
         and  DeviceApplied.status = 'not-done'
         return {id: DeviceApplied.id, requestStatusReason: DeviceApplied.statusReason, authoredOn: DeviceNotDoneTiming}

    )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-device-due-to-medical-reason-from-day-of-start-of-hospitalization-to-day-after-admission"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Device Due to Medical Reason From Day of Start of Hospitalization To Day After Admission&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
  	with &quot;No VTE Prophylaxis Device Applied or Ordered&quot; NoVTEDevice
      such that NoVTEDevice.requestStatusReason in &quot;Medical Reason&quot;
        and  NoVTEDevice.authoredOn during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-medication-due-to-medical-reason-on-day-of-or-day-after-procedure"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Medication Due to Medical Reason on Day of or Day After Procedure&quot;:
	from
  		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
  		[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
  		&quot;No VTE Prophylaxis Medication Administered or Ordered&quot; NoVTEMedication
	where Coalesce(NoVTEMedication.statusReason,NoVTEMedication.reasonCode) in &quot;Medical Reason&quot;
			and AnesthesiaProcedure.status = 'completed'
			and Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
			and Coalesce(NoVTEMedication.authoredOn, start of Global.&quot;Normalize Interval&quot;(NoVTEMedication.effective)) during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
  return QualifyingEncounter</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-device-due-to-medical-reason-on-day-of-or-day-after-procedure"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Device Due to Medical Reason on Day of or Day After Procedure&quot;:
  from
  		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
  		[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
  		&quot;No VTE Prophylaxis Device Applied or Ordered&quot; NoVTEDevice
  where  NoVTEDevice.requestStatusReason in &quot;Medical Reason&quot;
      and AnesthesiaProcedure.status = 'completed'
  		and Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
      and NoVTEDevice.authoredOn during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
  return QualifyingEncounter</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-no-vte-prophylaxis-due-to-medical-reason"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With No VTE Prophylaxis Due to Medical Reason&quot;:
   ( &quot;No VTE Prophylaxis Medication Due to Medical Reason From Day of Start of Hospitalization To Day After Admission&quot;
     intersect &quot;No VTE Prophylaxis Device Due to Medical Reason From Day of Start of Hospitalization To Day After Admission&quot;
   )
   union ( &quot;No VTE Prophylaxis Medication Due to Medical Reason on Day of or Day After Procedure&quot;
       intersect &quot;No VTE Prophylaxis Device Due to Medical Reason on Day of or Day After Procedure&quot;
       )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-medication-or-device-due-to-patient-refusal"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Medication or Device Due to Patient Refusal&quot;:
    ( &quot;No VTE Prophylaxis Medication Administered or Ordered&quot; NoVTEMedication
        where Coalesce(NoVTEMedication.statusReason,NoVTEMedication.reasonCode) in &quot;Patient Refusal&quot;
    )
  union (&quot;No VTE Prophylaxis Device Applied or Ordered&quot; NoVTEDevice
           where NoVTEDevice.requestStatusReason in &quot;Patient Refusal&quot;
        )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-due-to-patient-refusal-from-day-of-start-of-hospitalization-to-day-after-admission"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Due to Patient Refusal From Day of Start of Hospitalization To Day After Admission&quot;:
 	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
	 with &quot;No VTE Prophylaxis Medication or Device Due to Patient Refusal&quot; PatientRefusal
   such that Coalesce(start of Global.&quot;Normalize Interval&quot;(PatientRefusal.effective), PatientRefusal.authoredOn)
         during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-no-vte-prophylaxis-due-to-patient-refusal-on-day-of-or-day-after-procedure"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;No VTE Prophylaxis Due to Patient Refusal on Day of or Day After Procedure&quot;:
 	from
   		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
   		[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
   		&quot;No VTE Prophylaxis Medication or Device Due to Patient Refusal&quot; PatientRefusal
	where Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
 			and Coalesce(start of Global.&quot;Normalize Interval&quot;(PatientRefusal.effective), PatientRefusal.authoredOn)
             during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
	return QualifyingEncounter</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-no-vte-prophylaxis-due-to-patient-refusal"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With No VTE Prophylaxis Due to Patient Refusal&quot;:
 &quot;No VTE Prophylaxis Due to Patient Refusal From Day of Start of Hospitalization To Day After Admission&quot;
 	union &quot;No VTE Prophylaxis Due to Patient Refusal on Day of or Day After Procedure&quot;</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-numerator"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Numerator&quot;:
  &quot;Encounter With VTE Prophylaxis Received on Day of or Day After Admission or Procedure&quot;
    union ( &quot;Encounter With Medication Oral Factor Xa Inhibitor Administered on Day of or Day After Admission or Procedure&quot;
    			  intersect ( &quot;Encounter With Prior or Present Diagnosis of Atrial Fibrillation or VTE&quot;
    						    union &quot;Encounter With Prior or Present Procedure of Hip or Knee Replacement Surgery&quot;
    			            )
          )
    union &quot;Encounter With Low Risk for VTE or Anticoagulant Administered&quot;
    union &quot;Encounter With No VTE Prophylaxis Due to Medical Reason&quot;
    union &quot;Encounter With No VTE Prophylaxis Due to Patient Refusal&quot;</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-initial-population"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Initial Population&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot;</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-denominator"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Denominator&quot;:
      &quot;Initial Population&quot;</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-sde-payer"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SDE Payer&quot;:
	SDE.&quot;SDE Payer&quot;</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-sde-ethnicity"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SDE Ethnicity&quot;:
  SDE.&quot;SDE Ethnicity&quot;</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-less-than-2-days"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter Less Than 2 Days&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
  	where Global.&quot;LengthInDays&quot;(QualifyingEncounter.period)&lt; 2</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-icu-location-stay-1-day-or-more"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With ICU Location Stay 1 Day or More&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    where exists ( QualifyingEncounter.location Location
    		where Global.GetLocation(Location.location).type in &quot;Intensive Care Unit&quot;
    			and Global.&quot;LengthInDays&quot;(Location.period)&gt;= 1
    			and Location.period starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(start of QualifyingEncounter.period)
	    )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-principal-diagnosis-of-mental-disorder-or-stroke"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With Principal Diagnosis of Mental Disorder or Stroke&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    where Global.&quot;PrincipalDiagnosis&quot;(QualifyingEncounter).code in &quot;Mental Health Diagnoses&quot;
        or Global.&quot;PrincipalDiagnosis&quot;(QualifyingEncounter).code in &quot;Hemorrhagic Stroke&quot;
        or Global.&quot;PrincipalDiagnosis&quot;(QualifyingEncounter).code in &quot;Ischemic Stroke&quot;</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-scip-vte-selected-surgery"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SCIP VTE Selected Surgery&quot;:
  (	[&quot;Procedure&quot;: &quot;General Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Gynecological Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Hip Fracture Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Hip Replacement Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Intracranial Neurosurgery&quot;]
    union [&quot;Procedure&quot;: &quot;Knee Replacement Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Urological Surgery&quot;] ) Procedure
  where Procedure.status = 'completed'</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-principal-procedure-of-scip-vte-selected-surgery"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With Principal Procedure of SCIP VTE Selected Surgery&quot;:
  from
    &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
    &quot;SCIP VTE Selected Surgery&quot; SelectedProcedure
  let EncounterProcedure: Global.GetExtension(QualifyingEncounter, 'qicore-encounter-procedure')
  where FHIRHelpers.ToInteger(Global.GetExtension(EncounterProcedure, 'rank').value as FHIR.positiveInt) = 1
    and Global.GetId(FHIRHelpers.ToString((Global.GetExtension(EncounterProcedure, 'procedure').value as FHIR.Reference).reference)) = SelectedProcedure.id
    and Global.&quot;Normalize Interval&quot;(SelectedProcedure.performed) during QualifyingEncounter.period</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-intervention-comfort-measures"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Intervention Comfort Measures&quot;:
	([&quot;ServiceRequest&quot;: &quot;Comfort Measures&quot;] P
    		where P.intent = 'order'
  )
  	union
    	([&quot;Procedure&quot;: &quot;Comfort Measures&quot;] InterventionPerformed
      	where InterventionPerformed.status in {'completed', 'in-progress'})</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-intervention-comfort-measures-from-day-of-start-of-hospitalization-to-day-after-admission"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With Intervention Comfort Measures From Day of Start of Hospitalization To Day After Admission&quot;:
	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
		with &quot;Intervention Comfort Measures&quot; ComfortMeasure
		such that Coalesce(start of Global.&quot;Normalize Interval&quot;(ComfortMeasure.performed), ComfortMeasure.authoredOn) during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-encounter-with-intervention-comfort-measures-on-day-of-or-day-after-procedure"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Encounter With Intervention Comfort Measures on Day of or Day After Procedure&quot;:
  from
    &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
    [&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
    &quot;Intervention Comfort Measures&quot; ComfortMeasure
  where AnesthesiaProcedure.status = 'completed'
      and Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
      and Coalesce(start of Global.&quot;Normalize Interval&quot;(ComfortMeasure.performed), ComfortMeasure.authoredOn) during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
  return QualifyingEncounter</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-denominator-exclusion"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Denominator Exclusion&quot;:
  &quot;Encounter Less Than 2 Days&quot;
     union &quot;Encounter With ICU Location Stay 1 Day or More&quot;
     union &quot;Encounter With Principal Diagnosis of Mental Disorder or Stroke&quot;
     union &quot;Encounter With Principal Procedure of SCIP VTE Selected Surgery&quot;
     union &quot;Encounter With Intervention Comfort Measures From Day of Start of Hospitalization To Day After Admission&quot;
     union &quot;Encounter With Intervention Comfort Measures on Day of or Day After Procedure&quot;</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-sde-race"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;SDE Race&quot;:
  SDE.&quot;SDE Race&quot;</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> EXM108</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="exm108-getstatusreason"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">//11/5: ServiceRequest not done reason is an extension in QI-Core R4 as ServiceRequest.extension:statusReason
define function GetStatusReason(requestReason ServiceRequest):
      Global.GetBaseExtension(requestReason, 'request-statusReason')</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        



        



        




        
        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-inpatient-encounter"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define &quot;Inpatient Encounter&quot;:
	[Encounter: &quot;Encounter Inpatient&quot;] EncounterInpatient
		where EncounterInpatient.status = 'finished'
		    and &quot;LengthInDays&quot;(EncounterInpatient.period) &lt;= 120
			and EncounterInpatient.period ends during &quot;Measurement Period&quot;</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-lengthindays"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;LengthInDays&quot;(Value Interval&lt;DateTime&gt;):
	difference in days between start of Value and end of Value</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-calendarageinyearsat"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;CalendarAgeInYearsAt&quot;(BirthDateTime DateTime, AsOf DateTime):
	years between ToDate(BirthDateTime)and ToDate(AsOf)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-todate"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;ToDate&quot;(Value DateTime):
	DateTime(year from Value, month from Value, day from Value, 0, 0, 0, 0, timezoneoffset from Value)</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-encounterdiagnosis"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;EncounterDiagnosis&quot;(Encounter Encounter):
  Encounter.diagnosis D
    return singleton from ([Condition] C where C.id = &quot;GetId&quot;(D.condition.reference))</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-getid"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;GetId&quot;(uri String):
	Last(Split(uri, '/'))</code></pre>
  </td>

</tr>



        



        



        



        



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-hospitalizationwithobservation"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;HospitalizationWithObservation&quot;(TheEncounter FHIR.Encounter):
	TheEncounter Visit
		let ObsVisit: Last([Encounter: &quot;Observation Services&quot;] LastObs
				where LastObs.period ends 1 hour or less on or before start of Visit.period
				sort by end of period
			),
			VisitStart: Coalesce(start of ObsVisit.period, start of Visit.period),
			EDVisit: Last([Encounter: &quot;Emergency Department Visit&quot;] LastED
				where LastED.period ends 1 hour or less on or before VisitStart
				sort by end of period
			)
		return Interval[Coalesce(start of EDVisit.period, VisitStart), end of Visit.period]</code></pre>
  </td>

</tr>



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-getbaseextension"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;GetBaseExtension&quot;(domainResource DomainResource, url String):
  singleton from &quot;GetBaseExtensions&quot;(domainResource, url)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-getbaseextensions"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">/*
NOTE: Extensions are not the preferred approach, but are used as a way to access
content that is defined by extensions but not yet surfaced in the
CQL model info.
*/
define function &quot;GetBaseExtensions&quot;(domainResource DomainResource, url String):
  domainResource.extension E
	  where E.url = ('http://hl7.org/fhir/StructureDefinition/' + url)
		return E</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-getextension"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;GetExtension&quot;(domainResource DomainResource, url String):
  singleton from &quot;GetExtensions&quot;(domainResource, url)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-getextensions"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">/*
NOTE: Extensions are not the preferred approach, but are used as a way to access
content that is defined by extensions but not yet surfaced in the
CQL model info.
*/
define function &quot;GetExtensions&quot;(domainResource DomainResource, url String):
  domainResource.extension E
	  where E.url = ('http://hl7.org/fhir/us/qicore/StructureDefinition/' + url)
		return E</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-getlocation"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">// Returns the location for the given location reference
define function GetLocation(reference Reference):
  singleton from (
    [Location] L where L.id = GetId(reference.reference)
  )</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-principaldiagnosis"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">// Returns the condition that is specified as the principal diagnosis for the encounter
// TODO: BTR 2019-07-30: Shouldn't need the FHIRHelpers reference here, investigate
define function &quot;PrincipalDiagnosis&quot;(Encounter Encounter):
	(singleton from (Encounter.diagnosis D where FHIRHelpers.ToInteger(D.rank) = 1)) PD
		return singleton from ([Condition] C where C.id = &quot;GetId&quot;(PD.condition.reference))</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-getextension"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function &quot;GetExtension&quot;(element Element, url String):
  singleton from &quot;GetExtensions&quot;(element, url)</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> MATGlobalCommonFunctions</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="matglobalcommonfunctions-getextensions"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">/*
NOTE: Extensions are not the preferred approach, but are used as a way to access
content that is defined by extensions but not yet surfaced in the
CQL model info.
*/
define function &quot;GetExtensions&quot;(element Element, url String):
  element.extension E
	  where E.url = (url)
		return E</code></pre>
  </td>

</tr>



        




        
        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value AdministrativeGender): value.value</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value EncounterStatus): value.value</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tointerval"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">/*
@description: Converts the given [Period](https://hl7.org/fhir/datatypes.html#Period)
value to a CQL DateTime Interval
@comment: If the start value of the given period is unspecified, the starting
boundary of the resulting interval will be open (meaning the start of the interval
is unknown, as opposed to interpreted as the beginning of time).
*/
define function ToInterval(period FHIR.Period):
    if period is null then
        null
    else
        if period.&quot;start&quot; is null then
            Interval(period.&quot;start&quot;.value, period.&quot;end&quot;.value]
        else
            Interval[period.&quot;start&quot;.value, period.&quot;end&quot;.value]</code></pre>
  </td>

</tr>



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-todate"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToDate(value date): value.value</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value string): value.value</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-toconcept"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">/*
@description: Converts the given FHIR [CodeableConcept](https://hl7.org/fhir/datatypes.html#CodeableConcept) value to a CQL Concept.
*/
define function ToConcept(concept FHIR.CodeableConcept):
    if concept is null then
        null
    else
        System.Concept {
            codes: concept.coding C return ToCode(C),
            display: concept.text.value
        }</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tocode"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">/*
@description: Converts the given FHIR [Coding](https://hl7.org/fhir/datatypes.html#Coding) value to a CQL Code.
*/
define function ToCode(coding FHIR.Coding):
    if coding is null then
        null
    else
        System.Code {
          code: coding.code.value,
          system: coding.system.value,
          version: coding.version.value,
          display: coding.display.value
        }</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value MedicationAdministrationStatus): value.value</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value ProcedureStatus): value.value</code></pre>
  </td>

</tr>



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value ObservationStatus): value.value</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-toquantity"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">/*
@description: Converts the given FHIR [Quantity](https://hl7.org/fhir/datatypes.html#Quantity) 
value to a CQL Quantity
@comment: If the given quantity has a comparator specified, a runtime error is raised. If the given quantity
has a system other than UCUM (i.e. `http://unitsofmeasure.org`) or CQL calendar units (i.e. `http://hl7.org/fhirpath/CodeSystem/calendar-units`)
an error is raised. For UCUM to calendar units, the `ToCalendarUnit` function is used.
@seealso: ToCalendarUnit
*/
define function ToQuantity(quantity FHIR.Quantity):
    case
        when quantity is null then null
        when quantity.value is null then null
        when quantity.comparator is not null then
            Message(null, true, 'FHIRHelpers.ToQuantity.ComparatorQuantityNotSupported', 'Error', 'FHIR Quantity value has a comparator and cannot be converted to a System.Quantity value.')
        when quantity.system is null or quantity.system.value = 'http://unitsofmeasure.org'
              or quantity.system.value = 'http://hl7.org/fhirpath/CodeSystem/calendar-units' then
            System.Quantity { value: quantity.value.value, unit: ToCalendarUnit(Coalesce(quantity.code.value, quantity.unit.value, '1')) }
        else
            Message(null, true, 'FHIRHelpers.ToQuantity.InvalidFHIRQuantity', 'Error', 'Invalid FHIR Quantity code: ' &amp; quantity.unit.value &amp; ' (' &amp; quantity.system.value &amp; '|' &amp; quantity.code.value &amp; ')')
    end</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tocalendarunit"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">/*
@description: Converts a UCUM definite duration unit to a CQL calendar duration
unit using conversions specified in the [quantities](https://cql.hl7.org/02-authorsguide.html#quantities) 
topic of the CQL specification.
@comment: Note that for durations above days (or weeks), the conversion is understood to be approximate
*/
define function ToCalendarUnit(unit System.String):
    case unit
        when 'ms' then 'millisecond'
        when 's' then 'second'
        when 'min' then 'minute'
        when 'h' then 'hour'
        when 'd' then 'day'
        when 'wk' then 'week'
        when 'mo' then 'month'
        when 'a' then 'year'
        else unit
    end</code></pre>
  </td>

</tr>



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-toboolean"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToBoolean(value boolean): value.value</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value MedicationRequestStatus): value.value</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-todatetime"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToDateTime(value dateTime): value.value</code></pre>
  </td>

</tr>



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value ServiceRequestStatus): value.value</code></pre>
  </td>

</tr>



        



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value uri): value.value</code></pre>
  </td>

</tr>



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-todatetime"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToDateTime(value instant): value.value</code></pre>
  </td>

</tr>



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tointeger"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToInteger(value integer): value.value</code></pre>
  </td>

</tr>



        



        



        


<tr>
  <th scope="row" rowspan="2" class="row-header">
    Logic Definition
  </th>

  <td class="content-container"><em>Library Name:</em> FHIRHelpers</td>

</tr>
<tr>

  <td>
    
    
    
    
      <a name="fhirhelpers-tostring"> </a>
    
    <pre style="border: none;" class="content-container highlight language-cql"><code class="language-cql">define function ToString(value ServiceRequestIntent): value.value</code></pre>
  </td>

</tr>





  
  


  <tr>


<th colspan="2" scope="row" class="row-header"><a name="terminology"> </a>Terminology</th>


</tr>
  
  
  

 

 

 

 

 


<tr>
  
  
  

<th scope="row" class="row-header">Code System</th>


  
  <td class="content-container">
    
    <em>Description</em>: Code system ConditionClinicalStatusCodes
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="http://terminology.hl7.org/6.5.0/CodeSystem-condition-clinical.html">Condition Clinical Status Codes</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</tt>
    
  </td>
</tr>
 


<tr>
  
  
  

<th scope="row" class="row-header">Code System</th>


  
  <td class="content-container">
    
    <em>Description</em>: Code system LOINC
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="http://terminology.hl7.org/6.5.0/CodeSystem-v3-loinc.html">Logical Observation Identifiers, Names and Codes (LOINC)</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://loinc.org</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Encounter Inpatient
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.666.5.307/expansion">Encounter Inpatient</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Obstetrics
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.263/expansion">Obstetrical or Pregnancy Related Conditions</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.263</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Venous Thromboembolism
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.279/expansion">Venous Thromboembolism</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.279</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Obstetrics VTE
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.264/expansion">Obstetrics VTE</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.264</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Low Dose Unfractionated Heparin for VTE Prophylaxis
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1045.39/expansion">Low Dose Unfractionated Heparin for VTE Prophylaxis</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1045.39</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Subcutaneous route
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.223/expansion">Subcutaneous route</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.223</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Low Molecular Weight Heparin for VTE Prophylaxis
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.219/expansion">Low Molecular Weight Heparin for VTE Prophylaxis</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.219</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Injectable Factor Xa Inhibitor for VTE Prophylaxis
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.211/expansion">Injectable Factor Xa Inhibitor for VTE Prophylaxis</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.211</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Warfarin
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.232/expansion">Warfarin</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.232</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Device Application
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1110.48/expansion">Device Application</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1110.48</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Intermittent pneumatic compression devices (IPC)
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.214/expansion">Intermittent pneumatic compression devices</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.214</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Venous foot pumps (VFP)
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.230/expansion">Venous foot pumps</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.230</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Graduated compression stockings (GCS)
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.256/expansion">Graduated compression stockings</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.256</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set General or Neuraxial Anesthesia
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.666.5.1743/expansion">General or Neuraxial Anesthesia</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.1743</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Oral Factor Xa Inhibitor for VTE Prophylaxis or VTE Treatment
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.134/expansion">Oral Factor Xa Inhibitor for VTE Prophylaxis or VTE Treatment</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.134</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Atrial Fibrillation/Flutter
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.202/expansion">Atrial Fibrillation or Flutter</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.202</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Hip Replacement Surgery
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.259/expansion">Hip Replacement Surgery</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.259</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Knee Replacement Surgery
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.261/expansion">Knee Replacement Surgery</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.261</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Low Risk
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.400/expansion">Low Risk</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.400</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set INR
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.213/expansion">INR</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.213</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Unfractionated Heparin
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.218/expansion">Unfractionated Heparin</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.218</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Intravenous route
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.222/expansion">Intravenous route</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.222</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Direct Thrombin Inhibitor
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.205/expansion">Direct Thrombin Inhibitor</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.205</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Glycoprotein IIb/IIIa Inhibitors
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1045.41/expansion">Glycoprotein IIb IIIa Inhibitors</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1045.41</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Observation Services
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1111.143/expansion">Observation Services</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Emergency Department Visit
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.292/expansion">Emergency Department Visit</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Medical Reason
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.473/expansion">Medical Reason For Not Providing Treatment</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.473</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Patient Refusal
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.93/expansion">Patient Refusal</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.93</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Payer
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.114222.4.11.3591/expansion">Payer Type</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Intensive Care Unit
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1110.23/expansion">Intensive Care Unit</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1110.23</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Mental Health Diagnoses
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.464.1003.105.12.1004/expansion">Mental Health Diagnoses</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.105.12.1004</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Hemorrhagic Stroke
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.212/expansion">Hemorrhagic Stroke</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.212</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Ischemic Stroke
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.247/expansion">Ischemic Stroke</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.247</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set General Surgery
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.255/expansion">General Surgery</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.255</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Gynecological Surgery
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.257/expansion">Gynecological Surgery</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.257</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Hip Fracture Surgery
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.258/expansion">Hip Fracture Surgery</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.258</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Intracranial Neurosurgery
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.260/expansion">Intracranial Neurosurgery</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.260</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Urological Surgery
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.272/expansion">Urological Surgery</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.272</tt>
    
  </td>
</tr>
 


<tr>
  
  

<th scope="row" class="row-header">Value Set</th>


  
  
  <td class="content-container">
    
    <em>Description</em>: Value set Comfort Measures
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="https://vsac.nlm.nih.gov/valueset/1.3.6.1.4.1.33895.1.3.0.45/expansion">Comfort Measures</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/1.3.6.1.4.1.33895.1.3.0.45</tt>
    
  </td>
</tr>
 


  
  <tr>
    <th scope="row" class="row-header">Direct Reference Code</th>
    <td class="content-container">
      
      <em>Code</em>: active
      <br/>
      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</tt>
    </td>
  </tr>

  <tr>
    <th scope="row" class="row-header">Direct Reference Code</th>
    <td class="content-container">
      
      <em>Code</em>: recurrence
      <br/>
      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</tt>
    </td>
  </tr>

  <tr>
    <th scope="row" class="row-header">Direct Reference Code</th>
    <td class="content-container">
      
      <em>Code</em>: relapse
      <br/>
      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</tt>
    </td>
  </tr>

  <tr>
    <th scope="row" class="row-header">Direct Reference Code</th>
    <td class="content-container">
      
      <em>Code</em>: inactive
      <br/>
      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</tt>
    </td>
  </tr>

  <tr>
    <th scope="row" class="row-header">Direct Reference Code</th>
    <td class="content-container">
      
      <em>Code</em>: remission
      <br/>
      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</tt>
    </td>
  </tr>

  <tr>
    <th scope="row" class="row-header">Direct Reference Code</th>
    <td class="content-container">
      
      <em>Code</em>: resolved
      <br/>
      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</tt>
    </td>
  </tr>

  <tr>
    <th scope="row" class="row-header">Direct Reference Code</th>
    <td class="content-container">
      
        <em>Display</em>: Risk for venous thromboembolism
        <br/>
      
      <em>Code</em>: 72136-5
      <br/>
      <em>System</em>: <tt>http://loinc.org</tt>
    </td>
  </tr>

  
  


  <tr>


<th colspan="2" scope="row" class="row-header"><a name="dependencies"> </a>Dependencies</th>


</tr>
  
  
  


<tr>
  

<th scope="row" class="row-header">Dependency</th>


  <td class="content-container">
    
    <em>Description</em>: Library SDE
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="Library-SupplementalDataElements.html">Supplemental Data Elementsversion: null2.0.000)</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://hl7.org/fhir/uv/cqm/Library/SupplementalDataElements|2.0.000</tt>
    
  </td>
</tr>
 


<tr>
  

<th scope="row" class="row-header">Dependency</th>


  <td class="content-container">
    
    <em>Description</em>: Library FHIRHelpers
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="http://hl7.org/fhir/uv/cql/STU2/Library-FHIRHelpers.html">http://hl7.org/fhir/uv/cql/Library/FHIRHelpers|4.0.1</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://hl7.org/fhir/uv/cql/Library/FHIRHelpers|4.0.1</tt>
    
  </td>
</tr>
 


<tr>
  

<th scope="row" class="row-header">Dependency</th>


  <td class="content-container">
    
    <em>Description</em>: Library Global
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="Library-MATGlobalCommonFunctions.html">MAT Global Common Functions FHIR Libraryversion: null5.0.000)</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://hl7.org/fhir/uv/cqm/Library/MATGlobalCommonFunctions|5.0.000</tt>
    
  </td>
</tr>
 


<tr>
  

<th scope="row" class="row-header">Dependency</th>


  <td class="content-container">
    
    <em>Description</em>: Library TJC
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="Library-TJCOverall.html">TJC Overall Libraryversion: null4.0.000)</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://hl7.org/fhir/uv/cqm/Library/TJCOverall|4.0.000</tt>
    
  </td>
</tr>
 


<tr>
  

<th scope="row" class="row-header">Dependency</th>


  <td class="content-container">
    
    <em>Description</em>: Library VTEICU
    
    <br/>
    
    
    
    
    
    
    <em>Resource</em>: <a href="Library-VTEICU.html">VTE ICU Libraryversion: null5.0.000)</a>
    <br/>
    <em>Canonical URL</em>: <tt>http://hl7.org/fhir/uv/cqm/Library/VTEICU|5.0.000</tt>
    
  </td>
</tr>
 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 


  
  


  <tr>


<th colspan="2" scope="row" class="row-header"><a name="data-requirements"> </a>Data Requirements</th>


</tr>
  
  
  
<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Patient
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/patient.html">Patient</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: url, extension, value
    <br/>
   
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Encounter
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/encounter.html">Encounter</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: type, status, period, condition, condition.reference, location, rank
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: type</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.666.5.307/expansion">Encounter Inpatient</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Encounter
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/encounter.html">Encounter</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: type, period, condition, condition.reference, location, rank
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: type</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1111.143/expansion">Observation Services</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Encounter
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/encounter.html">Encounter</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: type, period, condition, condition.reference, location, rank
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: type</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.292/expansion">Emergency Department Visit</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Condition
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/condition.html">Condition</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, clinicalStatus, onset
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.202/expansion">Atrial Fibrillation or Flutter</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Condition
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/condition.html">Condition</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, clinicalStatus, onset
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.279/expansion">Venous Thromboembolism</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Condition
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/condition.html">Condition</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: id, code
    <br/>
   
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, status, effective, dosage, dosage.route, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.134/expansion">Oral Factor Xa Inhibitor for VTE Prophylaxis or VTE Treatment</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, dosage, dosage.route, status, id, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.218/expansion">Unfractionated Heparin</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, dosage, dosage.route, status, id, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.205/expansion">Direct Thrombin Inhibitor</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, dosage, dosage.route, status, id, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1045.41/expansion">Glycoprotein IIb IIIa Inhibitors</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication.reference, dosage, dosage.route, status, id, effective
    <br/>
   
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, status, dosage, dosage.route, id, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1045.39/expansion">Low Dose Unfractionated Heparin for VTE Prophylaxis</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, status, dosage, dosage.route, id, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.219/expansion">Low Molecular Weight Heparin for VTE Prophylaxis</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, status, dosage, dosage.route, id, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.211/expansion">Injectable Factor Xa Inhibitor for VTE Prophylaxis</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationAdministration
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationadministration.html">MedicationAdministration</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, status, dosage, dosage.route, id, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.232/expansion">Warfarin</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, usedCode, performed, id, statusReason
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1110.48/expansion">Device Application</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, performed, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.255/expansion">General Surgery</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, performed, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.257/expansion">Gynecological Surgery</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, performed, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.258/expansion">Hip Fracture Surgery</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, performed, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.259/expansion">Hip Replacement Surgery</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, performed, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.260/expansion">Intracranial Neurosurgery</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, performed, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.261/expansion">Knee Replacement Surgery</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, performed, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.272/expansion">Urological Surgery</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, performed, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/1.3.6.1.4.1.33895.1.3.0.45/expansion">Comfort Measures</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Procedure
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/procedure.html">Procedure</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, performed, status, id
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.666.5.1743/expansion">General or Neuraxial Anesthesia</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Observation
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/observation.html">Observation</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, value, status, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
  
    <span class="tab-one"><em>Code(s)</em>: 
    
      
      <a href="https://loinc.org/72136-5">LOINC 72136-5</a>: Risk for venous thromboembolism
      
    
    </span>
    <br/>
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Observation
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/observation.html">Observation</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, value, status, id, issued, effective
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.213/expansion">INR</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Medication
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medication.html">Medication</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: id, code
    <br/>
   
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationRequest
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationrequest.html">MedicationRequest</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, doNotPerform, status
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113762.1.4.1045.39/expansion">Low Dose Unfractionated Heparin for VTE Prophylaxis</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationRequest
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationrequest.html">MedicationRequest</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, doNotPerform, status
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.219/expansion">Low Molecular Weight Heparin for VTE Prophylaxis</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationRequest
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationrequest.html">MedicationRequest</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, doNotPerform, status
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.211/expansion">Injectable Factor Xa Inhibitor for VTE Prophylaxis</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: MedicationRequest
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/medicationrequest.html">MedicationRequest</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: medication, doNotPerform, status
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: medication</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.232/expansion">Warfarin</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: ServiceRequest
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/servicerequest.html">ServiceRequest</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, doNotPerform, id, authoredOn
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.230/expansion">Venous foot pumps</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: ServiceRequest
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/servicerequest.html">ServiceRequest</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, doNotPerform, id, authoredOn
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.214/expansion">Intermittent pneumatic compression devices</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: ServiceRequest
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/servicerequest.html">ServiceRequest</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, status, doNotPerform, id, authoredOn
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.113883.3.117.1.7.1.256/expansion">Graduated compression stockings</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: ServiceRequest
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/servicerequest.html">ServiceRequest</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: code, intent, status, doNotPerform, id, authoredOn
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: code</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/1.3.6.1.4.1.33895.1.3.0.45/expansion">Comfort Measures</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Coverage
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/coverage.html">Coverage</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: type, period
    <br/>
   
  
    <em>Code Filter(s)</em>: 
    <br/>
  
  
    <span class="tab-one"><em>Path</em>: type</span>
    <br/>
  
  
  
    <span class="tab-one"><em>ValueSet</em>:</span> <a href="https://vsac.nlm.nih.gov/valueset/2.16.840.1.114222.4.11.3591/expansion">Payer Type</a>
    <br/> 
  
  
  
   
  </td>
</tr>

<tr>
  <th scope="row" class="row-header">Data Requirement</th>
  <td class="content-container">
    <em>Type</em>: Location
    <br/>
  
    <em>Profile(s)</em>: 
  
    <a href="http://hl7.org/fhir/R4/location.html">Location</a>
    <br/>        
  
   
   
    <em>Must Support Elements</em>: id
    <br/>
   
   
  </td>
</tr>

  
  

<tr>
  <th colspan="2" scope="row" class="row-header">Generated using version 0.4.9 of the sample-content-ig Liquid templates</th>
</tr>

    </tbody>
  </table>
</div>
  </text>
  <contained>
    <Library>
      <id value="effective-data-requirements"/>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode">
        <valueCoding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/condition-clinical"/>
          <code value="active"/>
        </valueCoding>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode">
        <valueCoding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/condition-clinical"/>
          <code value="recurrence"/>
        </valueCoding>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode">
        <valueCoding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/condition-clinical"/>
          <code value="relapse"/>
        </valueCoding>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode">
        <valueCoding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/condition-clinical"/>
          <code value="inactive"/>
        </valueCoding>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode">
        <valueCoding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/condition-clinical"/>
          <code value="remission"/>
        </valueCoding>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode">
        <valueCoding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/condition-clinical"/>
          <code value="resolved"/>
        </valueCoding>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode">
        <valueCoding>
          <system value="http://loinc.org"/>
          <code value="72136-5"/>
          <display value="Risk for venous thromboembolism"/>
        </valueCoding>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="SupplementalDataElements"/>
        </extension>
        <extension url="name">
          <valueString value="SDE Sex"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SDE Sex&quot;:
  case
      when Patient.gender = 'male' then Code { code: 'M', system: 'http://hl7.org/fhir/v3/AdministrativeGender', display: 'Male' }
      when Patient.gender = 'female' then Code { code: 'F', system: 'http://hl7.org/fhir/v3/AdministrativeGender', display: 'Female' }
      else null
    end"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="0"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="SDE Sex"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SDE Sex&quot;:
	SDE.&quot;SDE Sex&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="1"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="Inpatient Encounter"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Inpatient Encounter&quot;:
	[Encounter: &quot;Encounter Inpatient&quot;] EncounterInpatient
		where EncounterInpatient.status = 'finished'
		    and &quot;LengthInDays&quot;(EncounterInpatient.period) &lt;= 120
			and EncounterInpatient.period ends during &quot;Measurement Period&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="2"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Admission Without VTE or Obstetrical Conditions"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Admission Without VTE or Obstetrical Conditions&quot;:
  Global.&quot;Inpatient Encounter&quot; InpatientEncounter
    where not exists (
      (Global.EncounterDiagnosis(InpatientEncounter)) EncounterDiagnosis
        where EncounterDiagnosis.code in &quot;Obstetrics&quot;
          or EncounterDiagnosis.code in &quot;Venous Thromboembolism&quot;
          or EncounterDiagnosis.code in &quot;Obstetrics VTE&quot;
    )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="3"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="// Note: added FHIRHelpers.ToDate() in R4
define &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot;:
  ( Global.&quot;Inpatient Encounter&quot; InpatientEncounter
        where Global.&quot;CalendarAgeInYearsAt&quot;(FHIRHelpers.ToDate(Patient.birthDate), start of InpatientEncounter.period) &gt;= 18
  )
    intersect &quot;Admission Without VTE or Obstetrical Conditions&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="4"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="VTE Prophylaxis by Medication Administered or Device Applied"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="// 10/29: Replaced DeviceUseStatement with Procedure with a new value set and procedure.usdCode for specifying devices
define &quot;VTE Prophylaxis by Medication Administered or Device Applied&quot;:
  ( [&quot;MedicationAdministration&quot;: medication in &quot;Low Dose Unfractionated Heparin for VTE Prophylaxis&quot;] VTEMedication
      where VTEMedication.status ='completed'
			     and VTEMedication.dosage.route in &quot;Subcutaneous route&quot;
  )
   union ([&quot;MedicationAdministration&quot;: medication in &quot;Low Molecular Weight Heparin for VTE Prophylaxis&quot;] LMWH where LMWH.status = 'completed')
    union ([&quot;MedicationAdministration&quot;: medication in &quot;Injectable Factor Xa Inhibitor for VTE Prophylaxis&quot;] FactorXa where FactorXa.status = 'completed')
     union ([&quot;MedicationAdministration&quot;: medication in &quot;Warfarin&quot;] Warfarin where Warfarin.status = 'completed')
      union (
          [&quot;Procedure&quot;: &quot;Device Application&quot;] DeviceApplied
          where DeviceApplied.status = 'complete'
                and (DeviceApplied.usedCode in &quot;Intermittent pneumatic compression devices (IPC)&quot;
                    or DeviceApplied.usedCode in&quot;Venous foot pumps (VFP)&quot;
                    or DeviceApplied.usedCode in &quot;Graduated compression stockings (GCS)&quot;
                    )
          )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="5"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With VTE Prophylaxis Received on Day of or Day After Admission or Procedure"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With VTE Prophylaxis Received on Day of or Day After Admission or Procedure&quot;:
 	( from
      &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
      &quot;VTE Prophylaxis by Medication Administered or Device Applied&quot; VTEProphylaxis
    where Coalesce(Global.&quot;Normalize Interval&quot;(VTEProphylaxis.effective), Global.&quot;Normalize Interval&quot;(VTEProphylaxis.performed)) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(start of QualifyingEncounter.period)
    return QualifyingEncounter
 	)
 	union (
    from
      &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
      [&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
      &quot;VTE Prophylaxis by Medication Administered or Device Applied&quot; VTEProphylaxis
    where Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
      and Coalesce(Global.&quot;Normalize Interval&quot;(VTEProphylaxis.effective), Global.&quot;Normalize Interval&quot;(VTEProphylaxis.performed)) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
    return QualifyingEncounter
	)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="6"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Medication Oral Factor Xa Inhibitor Administered on Day of or Day After Admission or Procedure"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With Medication Oral Factor Xa Inhibitor Administered on Day of or Day After Admission or Procedure&quot;:
	( from
    		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
  			[&quot;MedicationAdministration&quot;: medication in &quot;Oral Factor Xa Inhibitor for VTE Prophylaxis or VTE Treatment&quot;] FactorXaMedication
    where FactorXaMedication.status = 'completed'
      and Global.&quot;Normalize Interval&quot;(FactorXaMedication.effective) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(start of QualifyingEncounter.period)
    return QualifyingEncounter
    )
    union ( from
    				  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
      				[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
      				[&quot;MedicationAdministration&quot;: medication in &quot;Oral Factor Xa Inhibitor for VTE Prophylaxis or VTE Treatment&quot;] FactorXaMedication
      			where FactorXaMedication.status = 'completed'
                and AnesthesiaProcedure.status = 'completed'
      			    and Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
      					and Global.&quot;Normalize Interval&quot;(FactorXaMedication.effective) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
      			return QualifyingEncounter
      		)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="7"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Prior or Present Diagnosis of Atrial Fibrillation or VTE"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With Prior or Present Diagnosis of Atrial Fibrillation or VTE&quot;:
	( &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
		with [&quot;Condition&quot;: code in &quot;Atrial Fibrillation/Flutter&quot;] AtrialFibrillation
		such that FHIRHelpers.ToConcept(AtrialFibrillation.clinicalStatus) in { Global.&quot;active&quot;, Global.&quot;recurrence&quot;, Global.&quot;relapse&quot; }
			and Global.&quot;Normalize Interval&quot;(AtrialFibrillation.onset) starts on or before end of QualifyingEncounter.period
    )
    union ( &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    				where Global.EncounterDiagnosis(QualifyingEncounter).code in &quot;Atrial Fibrillation/Flutter&quot;
    			)
    union ( &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    				with [&quot;Condition&quot;: code in &quot;Venous Thromboembolism&quot;] VTEDiagnosis
    				such that  FHIRHelpers.ToConcept(VTEDiagnosis.clinicalStatus) in { Global.&quot;inactive&quot;, Global.&quot;remission&quot;, Global.&quot;resolved&quot; }
      					//and VTEDiagnosis.verificationStatus = 'confirmed'
    				and Global.&quot;Normalize Interval&quot;(VTEDiagnosis.onset) before start of QualifyingEncounter.period
      		)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="8"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Prior or Present Procedure of Hip or Knee Replacement Surgery"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With Prior or Present Procedure of Hip or Knee Replacement Surgery&quot;:
	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
	with ( [&quot;Procedure&quot;: &quot;Hip Replacement Surgery&quot;]
    			union [&quot;Procedure&quot;: &quot;Knee Replacement Surgery&quot;] ) HipKneeProcedure
	such that HipKneeProcedure.status = 'completed'
	     and Global.&quot;Normalize Interval&quot;(HipKneeProcedure.performed) starts on or before end of QualifyingEncounter.period"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="9"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="Is In Low Risk for VTE or On Anticoagulant"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Is In Low Risk for VTE or On Anticoagulant&quot;:
	  ( [&quot;Observation&quot;: &quot;Risk for venous thromboembolism&quot;] VTERiskAssessment
			  where VTERiskAssessment.value in &quot;Low Risk&quot;
        and VTERiskAssessment.status in {'final','amended', 'corrected'}
	  )
  union ( [&quot;Observation&quot;: &quot;INR&quot;] INRLabTest
        where INRLabTest.value as Quantity &gt; 3.0
            and INRLabTest.status in {'final','amended', 'corrected'}
        return &quot;Observation&quot; { id: INRLabTest.id, effective: INRLabTest.issued }
        )
  union ((( [&quot;MedicationAdministration&quot;: &quot;Unfractionated Heparin&quot;] UnfractionatedHeparin
          where UnfractionatedHeparin.dosage.route in &quot;Intravenous route&quot;
         )
         union [&quot;MedicationAdministration&quot;: &quot;Direct Thrombin Inhibitor&quot;]
         union [&quot;MedicationAdministration&quot;: &quot;Glycoprotein IIb/IIIa Inhibitors&quot;] ) AnticoagulantMedication
         where AnticoagulantMedication.status = 'complete'
         return &quot;Observation&quot; { id: AnticoagulantMedication.id, effective: AnticoagulantMedication.effective }
      )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="10"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Low Risk for VTE or Anticoagulant Administered From Day of Start of Hospitalization To Day After Admission"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Low Risk for VTE or Anticoagulant Administered From Day of Start of Hospitalization To Day After Admission&quot;:
 	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    with &quot;Is In Low Risk for VTE or On Anticoagulant&quot; VTERiskAssessment
    such that Global.&quot;Normalize Interval&quot;(VTERiskAssessment.effective) starts during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="11"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Low Risk for VTE or Anticoagulant Administered on Day of or Day After Procedure"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Low Risk for VTE or Anticoagulant Administered on Day of or Day After Procedure&quot;:
 	from
   		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
   		[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
   		&quot;Is In Low Risk for VTE or On Anticoagulant&quot; VTERiskAssessment
	where Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
 			and Global.&quot;Normalize Interval&quot;(VTERiskAssessment.effective) starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
	return QualifyingEncounter"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="12"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Low Risk for VTE or Anticoagulant Administered"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With Low Risk for VTE or Anticoagulant Administered&quot;:
   &quot;Low Risk for VTE or Anticoagulant Administered From Day of Start of Hospitalization To Day After Admission&quot;
   	 union &quot;Low Risk for VTE or Anticoagulant Administered on Day of or Day After Procedure&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="13"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="No VTE Prophylaxis Medication Administered or Ordered"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Medication Administered or Ordered&quot;:
   ((	[&quot;MedicationAdministration&quot;: medication in &quot;Low Dose Unfractionated Heparin for VTE Prophylaxis&quot;]
     union
	    [&quot;MedicationAdministration&quot;: medication in &quot;Low Molecular Weight Heparin for VTE Prophylaxis&quot;]
     union
	    [&quot;MedicationAdministration&quot;: medication in &quot;Injectable Factor Xa Inhibitor for VTE Prophylaxis&quot;]
     union
	    [&quot;MedicationAdministration&quot;: medication in &quot;Warfarin&quot;]
       ) MedicationAdm
       where MedicationAdm.status = 'not-done'
        )
  union
	   ((	[&quot;MedicationRequest&quot;: medication in &quot;Low Dose Unfractionated Heparin for VTE Prophylaxis&quot;]
  	union
  	 [&quot;MedicationRequest&quot;: medication in &quot;Low Molecular Weight Heparin for VTE Prophylaxis&quot;]
    union
    	[&quot;MedicationRequest&quot;: medication in &quot;Injectable Factor Xa Inhibitor for VTE Prophylaxis&quot;]
    union
    	[&quot;MedicationRequest&quot;: medication in &quot;Warfarin&quot;]
    ) MedicationOrder
    	where	MedicationOrder.doNotPerform is true
        and MedicationOrder.status in {'completed', 'cancelled'}
        //11/5 discussion: all expressions for QI-Core must include a status.
        //Therefore, we need ServiceRequest.status = completed; and MedicationRequest.status = cancelled (or completed, since cancelled indicates it was once ordered but intentionally never filled).
        //So the not done issue is handled by ServiceRequest.doNotPerform = True  Or MedicationRequest.doNotPerform = True
    )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="14"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="No VTE Prophylaxis Medication Due to Medical Reason From Day of Start of Hospitalization To Day After Admission"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Medication Due to Medical Reason From Day of Start of Hospitalization To Day After Admission&quot;:
   	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
       with	&quot;No VTE Prophylaxis Medication Administered or Ordered&quot; NoVTEMedication
     	such that Coalesce(NoVTEMedication.statusReason,NoVTEMedication.reasonCode) in &quot;Medical Reason&quot;
      			and Coalesce(NoVTEMedication.authoredOn, start of Global.&quot;Normalize Interval&quot;(NoVTEMedication.effective)) during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="15"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="No VTE Prophylaxis Device Applied or Ordered"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Device Applied or Ordered&quot;:
  ((
    [&quot;ServiceRequest&quot;: &quot;Venous foot pumps (VFP)&quot;]
    union [&quot;ServiceRequest&quot;: &quot;Intermittent pneumatic compression devices (IPC)&quot;]
    union [&quot;ServiceRequest&quot;: &quot;Graduated compression stockings (GCS)&quot;]
    ) DeviceOrder
    where DeviceOrder.status = 'completed'
        and DeviceOrder.doNotPerform is true
    return {id: DeviceOrder.id, requestStatusReason: GetStatusReason(DeviceOrder), authoredOn: DeviceOrder.authoredOn}
    )
  union
    (
      [&quot;Procedure&quot;: &quot;Device Application&quot;] DeviceApplied
      let DeviceNotDoneTiming: Global.GetExtension(DeviceApplied, 'qicore-recorded').value
      where (DeviceApplied.usedCode in &quot;Intermittent pneumatic compression devices (IPC)&quot;
            or DeviceApplied.usedCode in &quot;Venous foot pumps (VFP)&quot;
            or DeviceApplied.usedCode in &quot;Graduated compression stockings (GCS)&quot;
            )
         and  DeviceApplied.status = 'not-done'
         return {id: DeviceApplied.id, requestStatusReason: DeviceApplied.statusReason, authoredOn: DeviceNotDoneTiming}

    )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="16"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="No VTE Prophylaxis Device Due to Medical Reason From Day of Start of Hospitalization To Day After Admission"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Device Due to Medical Reason From Day of Start of Hospitalization To Day After Admission&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
  	with &quot;No VTE Prophylaxis Device Applied or Ordered&quot; NoVTEDevice
      such that NoVTEDevice.requestStatusReason in &quot;Medical Reason&quot;
        and  NoVTEDevice.authoredOn during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="17"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="No VTE Prophylaxis Medication Due to Medical Reason on Day of or Day After Procedure"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Medication Due to Medical Reason on Day of or Day After Procedure&quot;:
	from
  		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
  		[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
  		&quot;No VTE Prophylaxis Medication Administered or Ordered&quot; NoVTEMedication
	where Coalesce(NoVTEMedication.statusReason,NoVTEMedication.reasonCode) in &quot;Medical Reason&quot;
			and AnesthesiaProcedure.status = 'completed'
			and Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
			and Coalesce(NoVTEMedication.authoredOn, start of Global.&quot;Normalize Interval&quot;(NoVTEMedication.effective)) during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
  return QualifyingEncounter"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="18"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="No VTE Prophylaxis Device Due to Medical Reason on Day of or Day After Procedure"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Device Due to Medical Reason on Day of or Day After Procedure&quot;:
  from
  		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
  		[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
  		&quot;No VTE Prophylaxis Device Applied or Ordered&quot; NoVTEDevice
  where  NoVTEDevice.requestStatusReason in &quot;Medical Reason&quot;
      and AnesthesiaProcedure.status = 'completed'
  		and Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
      and NoVTEDevice.authoredOn during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
  return QualifyingEncounter"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="19"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With No VTE Prophylaxis Due to Medical Reason"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With No VTE Prophylaxis Due to Medical Reason&quot;:
   ( &quot;No VTE Prophylaxis Medication Due to Medical Reason From Day of Start of Hospitalization To Day After Admission&quot;
     intersect &quot;No VTE Prophylaxis Device Due to Medical Reason From Day of Start of Hospitalization To Day After Admission&quot;
   )
   union ( &quot;No VTE Prophylaxis Medication Due to Medical Reason on Day of or Day After Procedure&quot;
       intersect &quot;No VTE Prophylaxis Device Due to Medical Reason on Day of or Day After Procedure&quot;
       )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="20"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="No VTE Prophylaxis Medication or Device Due to Patient Refusal"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Medication or Device Due to Patient Refusal&quot;:
    ( &quot;No VTE Prophylaxis Medication Administered or Ordered&quot; NoVTEMedication
        where Coalesce(NoVTEMedication.statusReason,NoVTEMedication.reasonCode) in &quot;Patient Refusal&quot;
    )
  union (&quot;No VTE Prophylaxis Device Applied or Ordered&quot; NoVTEDevice
           where NoVTEDevice.requestStatusReason in &quot;Patient Refusal&quot;
        )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="21"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="No VTE Prophylaxis Due to Patient Refusal From Day of Start of Hospitalization To Day After Admission"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Due to Patient Refusal From Day of Start of Hospitalization To Day After Admission&quot;:
 	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
	 with &quot;No VTE Prophylaxis Medication or Device Due to Patient Refusal&quot; PatientRefusal
   such that Coalesce(start of Global.&quot;Normalize Interval&quot;(PatientRefusal.effective), PatientRefusal.authoredOn)
         during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="22"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="No VTE Prophylaxis Due to Patient Refusal on Day of or Day After Procedure"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;No VTE Prophylaxis Due to Patient Refusal on Day of or Day After Procedure&quot;:
 	from
   		&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
   		[&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
   		&quot;No VTE Prophylaxis Medication or Device Due to Patient Refusal&quot; PatientRefusal
	where Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
 			and Coalesce(start of Global.&quot;Normalize Interval&quot;(PatientRefusal.effective), PatientRefusal.authoredOn)
             during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
	return QualifyingEncounter"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="23"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With No VTE Prophylaxis Due to Patient Refusal"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With No VTE Prophylaxis Due to Patient Refusal&quot;:
 &quot;No VTE Prophylaxis Due to Patient Refusal From Day of Start of Hospitalization To Day After Admission&quot;
 	union &quot;No VTE Prophylaxis Due to Patient Refusal on Day of or Day After Procedure&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="24"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="Numerator"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Numerator&quot;:
  &quot;Encounter With VTE Prophylaxis Received on Day of or Day After Admission or Procedure&quot;
    union ( &quot;Encounter With Medication Oral Factor Xa Inhibitor Administered on Day of or Day After Admission or Procedure&quot;
    			  intersect ( &quot;Encounter With Prior or Present Diagnosis of Atrial Fibrillation or VTE&quot;
    						    union &quot;Encounter With Prior or Present Procedure of Hip or Knee Replacement Surgery&quot;
    			            )
          )
    union &quot;Encounter With Low Risk for VTE or Anticoagulant Administered&quot;
    union &quot;Encounter With No VTE Prophylaxis Due to Medical Reason&quot;
    union &quot;Encounter With No VTE Prophylaxis Due to Patient Refusal&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="25"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="Initial Population"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Initial Population&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="26"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="Denominator"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Denominator&quot;:
      &quot;Initial Population&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="27"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="SupplementalDataElements"/>
        </extension>
        <extension url="name">
          <valueString value="SDE Payer"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SDE Payer&quot;:
  [Coverage: type in &quot;Payer&quot;] Payer
        return {
          code: Payer.type,
          period: Payer.period
        }"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="28"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="SDE Payer"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SDE Payer&quot;:
	SDE.&quot;SDE Payer&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="29"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="SupplementalDataElements"/>
        </extension>
        <extension url="name">
          <valueString value="SDE Ethnicity"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SDE Ethnicity&quot;:
  (flatten (
      Patient.extension Extension
        where Extension.url = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity'
          return Extension.extension
    )) E
      where E.url = 'ombCategory'
        or E.url = 'detailed'
      return E.value as Coding"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="30"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="SDE Ethnicity"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SDE Ethnicity&quot;:
  SDE.&quot;SDE Ethnicity&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="31"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="Encounter Less Than 2 Days"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter Less Than 2 Days&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
  	where Global.&quot;LengthInDays&quot;(QualifyingEncounter.period)&lt; 2"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="32"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With ICU Location Stay 1 Day or More"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With ICU Location Stay 1 Day or More&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    where exists ( QualifyingEncounter.location Location
    		where Global.GetLocation(Location.location).type in &quot;Intensive Care Unit&quot;
    			and Global.&quot;LengthInDays&quot;(Location.period)&gt;= 1
    			and Location.period starts during TJC.&quot;CalendarDayOfOrDayAfter&quot;(start of QualifyingEncounter.period)
	    )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="33"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Principal Diagnosis of Mental Disorder or Stroke"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With Principal Diagnosis of Mental Disorder or Stroke&quot;:
  &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
    where Global.&quot;PrincipalDiagnosis&quot;(QualifyingEncounter).code in &quot;Mental Health Diagnoses&quot;
        or Global.&quot;PrincipalDiagnosis&quot;(QualifyingEncounter).code in &quot;Hemorrhagic Stroke&quot;
        or Global.&quot;PrincipalDiagnosis&quot;(QualifyingEncounter).code in &quot;Ischemic Stroke&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="34"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="SCIP VTE Selected Surgery"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SCIP VTE Selected Surgery&quot;:
  (	[&quot;Procedure&quot;: &quot;General Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Gynecological Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Hip Fracture Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Hip Replacement Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Intracranial Neurosurgery&quot;]
    union [&quot;Procedure&quot;: &quot;Knee Replacement Surgery&quot;]
    union [&quot;Procedure&quot;: &quot;Urological Surgery&quot;] ) Procedure
  where Procedure.status = 'completed'"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="35"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Principal Procedure of SCIP VTE Selected Surgery"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With Principal Procedure of SCIP VTE Selected Surgery&quot;:
  from
    &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
    &quot;SCIP VTE Selected Surgery&quot; SelectedProcedure
  let EncounterProcedure: Global.GetExtension(QualifyingEncounter, 'qicore-encounter-procedure')
  where FHIRHelpers.ToInteger(Global.GetExtension(EncounterProcedure, 'rank').value as FHIR.positiveInt) = 1
    and Global.GetId(FHIRHelpers.ToString((Global.GetExtension(EncounterProcedure, 'procedure').value as FHIR.Reference).reference)) = SelectedProcedure.id
    and Global.&quot;Normalize Interval&quot;(SelectedProcedure.performed) during QualifyingEncounter.period"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="36"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="Intervention Comfort Measures"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Intervention Comfort Measures&quot;:
	([&quot;ServiceRequest&quot;: &quot;Comfort Measures&quot;] P
    		where P.intent = 'order'
  )
  	union
    	([&quot;Procedure&quot;: &quot;Comfort Measures&quot;] InterventionPerformed
      	where InterventionPerformed.status in {'completed', 'in-progress'})"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="37"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Intervention Comfort Measures From Day of Start of Hospitalization To Day After Admission"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With Intervention Comfort Measures From Day of Start of Hospitalization To Day After Admission&quot;:
	&quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter
		with &quot;Intervention Comfort Measures&quot; ComfortMeasure
		such that Coalesce(start of Global.&quot;Normalize Interval&quot;(ComfortMeasure.performed), ComfortMeasure.authoredOn) during VTEICU.&quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(QualifyingEncounter)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="38"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString
                       value="Encounter With Intervention Comfort Measures on Day of or Day After Procedure"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Encounter With Intervention Comfort Measures on Day of or Day After Procedure&quot;:
  from
    &quot;Encounter With Age Range and Without VTE Diagnosis or Obstetrical Conditions&quot; QualifyingEncounter,
    [&quot;Procedure&quot;: &quot;General or Neuraxial Anesthesia&quot;] AnesthesiaProcedure,
    &quot;Intervention Comfort Measures&quot; ComfortMeasure
  where AnesthesiaProcedure.status = 'completed'
      and Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed) ends 1 day after day of start of QualifyingEncounter.period
      and Coalesce(start of Global.&quot;Normalize Interval&quot;(ComfortMeasure.performed), ComfortMeasure.authoredOn) during TJC.&quot;CalendarDayOfOrDayAfter&quot;(end of Global.&quot;Normalize Interval&quot;(AnesthesiaProcedure.performed))
  return QualifyingEncounter"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="39"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="Denominator Exclusion"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;Denominator Exclusion&quot;:
  &quot;Encounter Less Than 2 Days&quot;
     union &quot;Encounter With ICU Location Stay 1 Day or More&quot;
     union &quot;Encounter With Principal Diagnosis of Mental Disorder or Stroke&quot;
     union &quot;Encounter With Principal Procedure of SCIP VTE Selected Surgery&quot;
     union &quot;Encounter With Intervention Comfort Measures From Day of Start of Hospitalization To Day After Admission&quot;
     union &quot;Encounter With Intervention Comfort Measures on Day of or Day After Procedure&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="40"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="SupplementalDataElements"/>
        </extension>
        <extension url="name">
          <valueString value="SDE Race"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SDE Race&quot;:
  (flatten (
      Patient.extension Extension
        where Extension.url = 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-race'
          return Extension.extension
    )) E
      where E.url = 'ombCategory'
        or E.url = 'detailed'
      return E.value as Coding"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="41"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="SDE Race"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define &quot;SDE Race&quot;:
  SDE.&quot;SDE Race&quot;"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="42"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value AdministrativeGender): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="43"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value EncounterStatus): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="44"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="LengthInDays"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;LengthInDays&quot;(Value Interval&lt;DateTime&gt;):
	difference in days between start of Value and end of Value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="45"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToInterval"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="/*
@description: Converts the given [Period](https://hl7.org/fhir/datatypes.html#Period)
value to a CQL DateTime Interval
@comment: If the start value of the given period is unspecified, the starting
boundary of the resulting interval will be open (meaning the start of the interval
is unknown, as opposed to interpreted as the beginning of time).
*/
define function ToInterval(period FHIR.Period):
    if period is null then
        null
    else
        if period.&quot;start&quot; is null then
            Interval(period.&quot;start&quot;.value, period.&quot;end&quot;.value]
        else
            Interval[period.&quot;start&quot;.value, period.&quot;end&quot;.value]"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="46"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="CalendarAgeInYearsAt"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;CalendarAgeInYearsAt&quot;(BirthDateTime DateTime, AsOf DateTime):
	years between ToDate(BirthDateTime)and ToDate(AsOf)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="47"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="ToDate"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;ToDate&quot;(Value DateTime):
	DateTime(year from Value, month from Value, day from Value, 0, 0, 0, 0, timezoneoffset from Value)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="48"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToDate"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToDate(value date): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="49"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="EncounterDiagnosis"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;EncounterDiagnosis&quot;(Encounter Encounter):
  Encounter.diagnosis D
    return singleton from ([Condition] C where C.id = &quot;GetId&quot;(D.condition.reference))"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="50"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value string): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="51"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="GetId"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;GetId&quot;(uri String):
	Last(Split(uri, '/'))"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="52"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToConcept"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="/*
@description: Converts the given FHIR [CodeableConcept](https://hl7.org/fhir/datatypes.html#CodeableConcept) value to a CQL Concept.
*/
define function ToConcept(concept FHIR.CodeableConcept):
    if concept is null then
        null
    else
        System.Concept {
            codes: concept.coding C return ToCode(C),
            display: concept.text.value
        }"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="53"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToCode"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="/*
@description: Converts the given FHIR [Coding](https://hl7.org/fhir/datatypes.html#Coding) value to a CQL Code.
*/
define function ToCode(coding FHIR.Coding):
    if coding is null then
        null
    else
        System.Code {
          code: coding.code.value,
          system: coding.system.value,
          version: coding.version.value,
          display: coding.display.value
        }"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="54"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value MedicationAdministrationStatus): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="55"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value ProcedureStatus): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="56"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="TJCOverall"/>
        </extension>
        <extension url="name">
          <valueString value="CalendarDayOfOrDayAfter"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;CalendarDayOfOrDayAfter&quot;(StartValue DateTime ):
	Interval(Global.&quot;ToDate&quot;(StartValue), Global.&quot;ToDate&quot;(StartValue + 2 days))"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="57"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value ObservationStatus): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="58"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToQuantity"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="/*
@description: Converts the given FHIR [Quantity](https://hl7.org/fhir/datatypes.html#Quantity) 
value to a CQL Quantity
@comment: If the given quantity has a comparator specified, a runtime error is raised. If the given quantity
has a system other than UCUM (i.e. `http://unitsofmeasure.org`) or CQL calendar units (i.e. `http://hl7.org/fhirpath/CodeSystem/calendar-units`)
an error is raised. For UCUM to calendar units, the `ToCalendarUnit` function is used.
@seealso: ToCalendarUnit
*/
define function ToQuantity(quantity FHIR.Quantity):
    case
        when quantity is null then null
        when quantity.value is null then null
        when quantity.comparator is not null then
            Message(null, true, 'FHIRHelpers.ToQuantity.ComparatorQuantityNotSupported', 'Error', 'FHIR Quantity value has a comparator and cannot be converted to a System.Quantity value.')
        when quantity.system is null or quantity.system.value = 'http://unitsofmeasure.org'
              or quantity.system.value = 'http://hl7.org/fhirpath/CodeSystem/calendar-units' then
            System.Quantity { value: quantity.value.value, unit: ToCalendarUnit(Coalesce(quantity.code.value, quantity.unit.value, '1')) }
        else
            Message(null, true, 'FHIRHelpers.ToQuantity.InvalidFHIRQuantity', 'Error', 'Invalid FHIR Quantity code: ' &amp; quantity.unit.value &amp; ' (' &amp; quantity.system.value &amp; '|' &amp; quantity.code.value &amp; ')')
    end"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="59"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToCalendarUnit"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="/*
@description: Converts a UCUM definite duration unit to a CQL calendar duration
unit using conversions specified in the [quantities](https://cql.hl7.org/02-authorsguide.html#quantities) 
topic of the CQL specification.
@comment: Note that for durations above days (or weeks), the conversion is understood to be approximate
*/
define function ToCalendarUnit(unit System.String):
    case unit
        when 'ms' then 'millisecond'
        when 's' then 'second'
        when 'min' then 'minute'
        when 'h' then 'hour'
        when 'd' then 'day'
        when 'wk' then 'week'
        when 'mo' then 'month'
        when 'a' then 'year'
        else unit
    end"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="60"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="VTEICU"/>
        </extension>
        <extension url="name">
          <valueString
                       value="FromDayOfStartOfHospitalizationToDayAfterAdmission"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;FromDayOfStartOfHospitalizationToDayAfterAdmission&quot;(Encounter FHIR.Encounter ):
	Interval[Global.&quot;ToDate&quot;(start of Global.&quot;HospitalizationWithObservation&quot;(Encounter)), Global.&quot;ToDate&quot;(start of Encounter.period + 2 days))"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="61"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="HospitalizationWithObservation"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;HospitalizationWithObservation&quot;(TheEncounter FHIR.Encounter):
	TheEncounter Visit
		let ObsVisit: Last([Encounter: &quot;Observation Services&quot;] LastObs
				where LastObs.period ends 1 hour or less on or before start of Visit.period
				sort by end of period
			),
			VisitStart: Coalesce(start of ObsVisit.period, start of Visit.period),
			EDVisit: Last([Encounter: &quot;Emergency Department Visit&quot;] LastED
				where LastED.period ends 1 hour or less on or before VisitStart
				sort by end of period
			)
		return Interval[Coalesce(start of EDVisit.period, VisitStart), end of Visit.period]"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="62"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToBoolean"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToBoolean(value boolean): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="63"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value MedicationRequestStatus): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="64"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToDateTime"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToDateTime(value dateTime): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="65"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value ServiceRequestStatus): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="66"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="EXM108"/>
        </extension>
        <extension url="name">
          <valueString value="GetStatusReason"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="//11/5: ServiceRequest not done reason is an extension in QI-Core R4 as ServiceRequest.extension:statusReason
define function GetStatusReason(requestReason ServiceRequest):
      Global.GetBaseExtension(requestReason, 'request-statusReason')"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="67"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="GetBaseExtension"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;GetBaseExtension&quot;(domainResource DomainResource, url String):
  singleton from &quot;GetBaseExtensions&quot;(domainResource, url)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="68"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="GetBaseExtensions"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="/*
NOTE: Extensions are not the preferred approach, but are used as a way to access
content that is defined by extensions but not yet surfaced in the
CQL model info.
*/
define function &quot;GetBaseExtensions&quot;(domainResource DomainResource, url String):
  domainResource.extension E
	  where E.url = ('http://hl7.org/fhir/StructureDefinition/' + url)
		return E"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="69"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value uri): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="70"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="GetExtension"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;GetExtension&quot;(domainResource DomainResource, url String):
  singleton from &quot;GetExtensions&quot;(domainResource, url)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="71"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="GetExtensions"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="/*
NOTE: Extensions are not the preferred approach, but are used as a way to access
content that is defined by extensions but not yet surfaced in the
CQL model info.
*/
define function &quot;GetExtensions&quot;(domainResource DomainResource, url String):
  domainResource.extension E
	  where E.url = ('http://hl7.org/fhir/us/qicore/StructureDefinition/' + url)
		return E"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="72"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToDateTime"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToDateTime(value instant): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="73"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="GetLocation"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="// Returns the location for the given location reference
define function GetLocation(reference Reference):
  singleton from (
    [Location] L where L.id = GetId(reference.reference)
  )"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="74"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="PrincipalDiagnosis"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="// Returns the condition that is specified as the principal diagnosis for the encounter
// TODO: BTR 2019-07-30: Shouldn't need the FHIRHelpers reference here, investigate
define function &quot;PrincipalDiagnosis&quot;(Encounter Encounter):
	(singleton from (Encounter.diagnosis D where FHIRHelpers.ToInteger(D.rank) = 1)) PD
		return singleton from ([Condition] C where C.id = &quot;GetId&quot;(PD.condition.reference))"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="75"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToInteger"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToInteger(value integer): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="76"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="GetExtension"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function &quot;GetExtension&quot;(element Element, url String):
  singleton from &quot;GetExtensions&quot;(element, url)"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="77"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="MATGlobalCommonFunctions"/>
        </extension>
        <extension url="name">
          <valueString value="GetExtensions"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="/*
NOTE: Extensions are not the preferred approach, but are used as a way to access
content that is defined by extensions but not yet surfaced in the
CQL model info.
*/
define function &quot;GetExtensions&quot;(element Element, url String):
  element.extension E
	  where E.url = (url)
		return E"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="78"/>
        </extension>
      </extension>
      <extension
                 url="http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition">
        <extension url="libraryName">
          <valueString value="FHIRHelpers"/>
        </extension>
        <extension url="name">
          <valueString value="ToString"/>
        </extension>
        <extension url="statement">
          <valueString
                       value="define function ToString(value ServiceRequestIntent): value.value"/>
        </extension>
        <extension url="displaySequence">
          <valueInteger value="79"/>
        </extension>
      </extension>
      <name value="EffectiveDataRequirements"/>
      <status value="active"/>
      <type>
        <coding>
          <system value="http://terminology.hl7.org/CodeSystem/library-type"/>
          <code value="module-definition"/>
        </coding>
      </type>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Library SDE"/>
        <resource
                  value="http://hl7.org/fhir/uv/cqm/Library/SupplementalDataElements|2.0.000"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Library FHIRHelpers"/>
        <resource
                  value="http://hl7.org/fhir/uv/cql/Library/FHIRHelpers|4.0.1"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Library Global"/>
        <resource
                  value="http://hl7.org/fhir/uv/cqm/Library/MATGlobalCommonFunctions|5.0.000"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Library TJC"/>
        <resource
                  value="http://hl7.org/fhir/uv/cqm/Library/TJCOverall|4.0.000"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Library VTEICU"/>
        <resource value="http://hl7.org/fhir/uv/cqm/Library/VTEICU|5.0.000"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Code system ConditionClinicalStatusCodes"/>
        <resource
                  value="http://terminology.hl7.org/CodeSystem/condition-clinical"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Code system LOINC"/>
        <resource value="http://loinc.org"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Encounter Inpatient"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Obstetrics"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.263"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Venous Thromboembolism"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.279"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Obstetrics VTE"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.264"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display
                 value="Value set Low Dose Unfractionated Heparin for VTE Prophylaxis"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1045.39"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Subcutaneous route"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.223"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display
                 value="Value set Low Molecular Weight Heparin for VTE Prophylaxis"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.219"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display
                 value="Value set Injectable Factor Xa Inhibitor for VTE Prophylaxis"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.211"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Warfarin"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.232"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Device Application"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1110.48"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display
                 value="Value set Intermittent pneumatic compression devices (IPC)"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.214"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Venous foot pumps (VFP)"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.230"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Graduated compression stockings (GCS)"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.256"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set General or Neuraxial Anesthesia"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.1743"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display
                 value="Value set Oral Factor Xa Inhibitor for VTE Prophylaxis or VTE Treatment"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.134"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Atrial Fibrillation/Flutter"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.202"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Hip Replacement Surgery"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.259"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Knee Replacement Surgery"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.261"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Low Risk"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.400"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set INR"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.213"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Unfractionated Heparin"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.218"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Intravenous route"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.222"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Direct Thrombin Inhibitor"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.205"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Glycoprotein IIb/IIIa Inhibitors"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1045.41"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Observation Services"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Emergency Department Visit"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Medical Reason"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.473"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Patient Refusal"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.93"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Payer"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Intensive Care Unit"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1110.23"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Mental Health Diagnoses"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.105.12.1004"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Hemorrhagic Stroke"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.212"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Ischemic Stroke"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.247"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set General Surgery"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.255"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Gynecological Surgery"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.257"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Hip Fracture Surgery"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.258"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Intracranial Neurosurgery"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.260"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Urological Surgery"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.272"/>
      </relatedArtifact>
      <relatedArtifact>
        <type value="depends-on"/>
        <display value="Value set Comfort Measures"/>
        <resource
                  value="http://cts.nlm.nih.gov/fhir/ValueSet/1.3.6.1.4.1.33895.1.3.0.45"/>
      </relatedArtifact>
      <parameter>
        <name value="Measurement Period"/>
        <use value="in"/>
        <min value="0"/>
        <max value="1"/>
        <type value="Period"/>
      </parameter>
      <parameter>
        <name value="SDE Sex"/>
        <use value="out"/>
        <min value="0"/>
        <max value="1"/>
        <type value="Coding"/>
      </parameter>
      <parameter>
        <name value="Numerator"/>
        <use value="out"/>
        <min value="0"/>
        <max value="*"/>
        <type value="Encounter"/>
      </parameter>
      <parameter>
        <name value="Denominator"/>
        <use value="out"/>
        <min value="0"/>
        <max value="*"/>
        <type value="Encounter"/>
      </parameter>
      <parameter>
        <name value="SDE Payer"/>
        <use value="out"/>
        <min value="0"/>
        <max value="*"/>
        <type value="Resource"/>
      </parameter>
      <parameter>
        <name value="Initial Population"/>
        <use value="out"/>
        <min value="0"/>
        <max value="*"/>
        <type value="Encounter"/>
      </parameter>
      <parameter>
        <name value="SDE Ethnicity"/>
        <use value="out"/>
        <min value="0"/>
        <max value="*"/>
        <type value="Coding"/>
      </parameter>
      <parameter>
        <name value="Denominator Exclusion"/>
        <use value="out"/>
        <min value="0"/>
        <max value="*"/>
        <type value="Resource"/>
      </parameter>
      <parameter>
        <name value="SDE Race"/>
        <use value="out"/>
        <min value="0"/>
        <max value="*"/>
        <type value="Coding"/>
      </parameter>
      <dataRequirement>
        <type value="Patient"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Patient"/>
        <mustSupport value="url"/>
        <mustSupport value="extension"/>
        <mustSupport value="value"/>
      </dataRequirement>
      <dataRequirement>
        <type value="Encounter"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Encounter"/>
        <mustSupport value="type"/>
        <mustSupport value="status"/>
        <mustSupport value="period"/>
        <mustSupport value="condition"/>
        <mustSupport value="condition.reference"/>
        <mustSupport value="location"/>
        <mustSupport value="rank"/>
        <codeFilter>
          <path value="type"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Encounter"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Encounter"/>
        <mustSupport value="type"/>
        <mustSupport value="period"/>
        <mustSupport value="condition"/>
        <mustSupport value="condition.reference"/>
        <mustSupport value="location"/>
        <mustSupport value="rank"/>
        <codeFilter>
          <path value="type"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Encounter"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Encounter"/>
        <mustSupport value="type"/>
        <mustSupport value="period"/>
        <mustSupport value="condition"/>
        <mustSupport value="condition.reference"/>
        <mustSupport value="location"/>
        <mustSupport value="rank"/>
        <codeFilter>
          <path value="type"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Condition"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Condition"/>
        <mustSupport value="code"/>
        <mustSupport value="clinicalStatus"/>
        <mustSupport value="onset"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.202"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Condition"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Condition"/>
        <mustSupport value="code"/>
        <mustSupport value="clinicalStatus"/>
        <mustSupport value="onset"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.279"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Condition"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Condition"/>
        <mustSupport value="id"/>
        <mustSupport value="code"/>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication"/>
        <mustSupport value="status"/>
        <mustSupport value="effective"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.134"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="status"/>
        <mustSupport value="id"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.218"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="status"/>
        <mustSupport value="id"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.205"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="status"/>
        <mustSupport value="id"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1045.41"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication.reference"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="status"/>
        <mustSupport value="id"/>
        <mustSupport value="effective"/>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication"/>
        <mustSupport value="status"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="id"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1045.39"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication"/>
        <mustSupport value="status"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="id"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.219"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication"/>
        <mustSupport value="status"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="id"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.211"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationAdministration"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationAdministration"/>
        <mustSupport value="medication"/>
        <mustSupport value="status"/>
        <mustSupport value="dosage"/>
        <mustSupport value="dosage.route"/>
        <mustSupport value="id"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.232"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="usedCode"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <mustSupport value="statusReason"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1110.48"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.255"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.257"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.258"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.259"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.260"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.261"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.272"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="performed"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/1.3.6.1.4.1.33895.1.3.0.45"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Procedure"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Procedure"/>
        <mustSupport value="code"/>
        <mustSupport value="performed"/>
        <mustSupport value="status"/>
        <mustSupport value="id"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.1743"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Observation"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Observation"/>
        <mustSupport value="code"/>
        <mustSupport value="value"/>
        <mustSupport value="status"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="code"/>
          <code>
            <system value="http://loinc.org"/>
            <code value="72136-5"/>
            <display value="Risk for venous thromboembolism"/>
          </code>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Observation"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Observation"/>
        <mustSupport value="code"/>
        <mustSupport value="value"/>
        <mustSupport value="status"/>
        <mustSupport value="id"/>
        <mustSupport value="issued"/>
        <mustSupport value="effective"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.213"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Medication"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Medication"/>
        <mustSupport value="id"/>
        <mustSupport value="code"/>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationRequest"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationRequest"/>
        <mustSupport value="medication"/>
        <mustSupport value="doNotPerform"/>
        <mustSupport value="status"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1045.39"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationRequest"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationRequest"/>
        <mustSupport value="medication"/>
        <mustSupport value="doNotPerform"/>
        <mustSupport value="status"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.219"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationRequest"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationRequest"/>
        <mustSupport value="medication"/>
        <mustSupport value="doNotPerform"/>
        <mustSupport value="status"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.211"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="MedicationRequest"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/MedicationRequest"/>
        <mustSupport value="medication"/>
        <mustSupport value="doNotPerform"/>
        <mustSupport value="status"/>
        <codeFilter>
          <path value="medication"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.232"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="ServiceRequest"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/ServiceRequest"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="doNotPerform"/>
        <mustSupport value="id"/>
        <mustSupport value="authoredOn"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.230"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="ServiceRequest"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/ServiceRequest"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="doNotPerform"/>
        <mustSupport value="id"/>
        <mustSupport value="authoredOn"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.214"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="ServiceRequest"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/ServiceRequest"/>
        <mustSupport value="code"/>
        <mustSupport value="status"/>
        <mustSupport value="doNotPerform"/>
        <mustSupport value="id"/>
        <mustSupport value="authoredOn"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.256"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="ServiceRequest"/>
        <profile
                 value="http://hl7.org/fhir/StructureDefinition/ServiceRequest"/>
        <mustSupport value="code"/>
        <mustSupport value="intent"/>
        <mustSupport value="status"/>
        <mustSupport value="doNotPerform"/>
        <mustSupport value="id"/>
        <mustSupport value="authoredOn"/>
        <codeFilter>
          <path value="code"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/1.3.6.1.4.1.33895.1.3.0.45"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Coverage"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Coverage"/>
        <mustSupport value="type"/>
        <mustSupport value="period"/>
        <codeFilter>
          <path value="type"/>
          <valueSet
                    value="http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591"/>
        </codeFilter>
      </dataRequirement>
      <dataRequirement>
        <type value="Location"/>
        <profile value="http://hl7.org/fhir/StructureDefinition/Location"/>
        <mustSupport value="id"/>
      </dataRequirement>
    </Library>
  </contained>
  <extension
             url="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-populationBasis">
    <valueCode value="Encounter"/>
  </extension>
  <extension
             url="http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-effectiveDataRequirements" id="effective-data-requirements">
    <valueCanonical value="#effective-data-requirements"/>
  </extension>
  <url value="http://hl7.org/fhir/uv/cqm/Measure/EXM108-FHIR"/>
  <identifier>
    <use value="official"/>
    <system value="http://example.org/fhir/cqi/ecqm/Measure/Identifier/cms"/>
    <value value="108"/>
  </identifier>
  <identifier>
    <system value="urn:ietf:rfc:3986"/>
    <value value="urn:oid:2.16.840.1.113883.4.642.40.61.29.3"/>
  </identifier>
  <version value="8.2.000"/>
  <name value="EXM108"/>
  <title value="EXM108 - Venous Thromboembolism Prophylaxis"/>
  <status value="active"/>
  <experimental value="true"/>
  <date value="2025-08-13"/>
  <publisher value="HL7 International / Clinical Quality Information"/>
  <contact>
    <telecom>
      <system value="url"/>
      <value value="http://www.hl7.org/Special/committees/cqi"/>
    </telecom>
  </contact>
  <description
               value="This measure assesses the number of patients who received VTE prophylaxis or have documentation why no VTE prophylaxis was given the day of or the day after hospital admission or surgery end date for surgeries that start the day of or the day after hospital admission"/>
  <useContext>
    <code>
      <system
              value="http://terminology.hl7.org/CodeSystem/usage-context-type"/>
      <code value="venue"/>
      <display value="Clinical Venue"/>
    </code>
    <valueCodeableConcept>
      <coding>
        <system
                value="http://hl7.org/fhir/uv/cqm/CodeSystem/intended-venue-codes"/>
        <code value="eh"/>
        <display value="EH"/>
      </coding>
    </valueCodeableConcept>
  </useContext>
  <jurisdiction>
    <coding>
      <system value="http://unstats.un.org/unsd/methods/m49/m49.htm"/>
      <code value="001"/>
    </coding>
  </jurisdiction>
  <copyright
             value="Measure specifications are in the Public Domain.

LOINC(R) is a registered trademark of the Regenstrief Institute.

This material contains SNOMED Clinical Terms(R) (SNOMED CT(C)) copyright 2004-2017 International Health Terminology Standards Development Organization. All rights reserved."/>
  <approvalDate value="2019-03-08"/>
  <lastReviewDate value="2019-03-08"/>
  <effectivePeriod>
    <start value="2018-01-01"/>
    <end value="2018-12-31"/>
  </effectivePeriod>
  <topic>
    <coding>
      <system value="http://loinc.org"/>
      <code value="57024-2"/>
      <display value="Health Quality Measure Document"/>
    </coding>
  </topic>
  <library value="http://hl7.org/fhir/uv/cqm/Library/EXM108"/>
  <disclaimer
              value="These performance measures are not clinical guidelines and do not establish a standard of medical care, and have not been tested for all potential applications. The measures and specifications are provided without warranty"/>
  <scoring>
    <coding>
      <system value="http://terminology.hl7.org/CodeSystem/measure-scoring"/>
      <code value="proportion"/>
      <display value="Proportion"/>
    </coding>
  </scoring>
  <type>
    <coding>
      <system value="http://terminology.hl7.org/CodeSystem/measure-type"/>
      <code value="process"/>
    </coding>
  </type>
  <rationale
             value="Hospitalized patients at high-risk for VTE may develop an asymptomatic deep vein thrombosis (DVT), and die from pulmonary embolism (PE) even before the diagnosis is suspected. The majority of fatal events occur as sudden or abrupt death, underscoring the importance of prevention as the most critical action step for reducing death from PE (Geerts, et al, 2008).

The estimated annual incidence of deep-vein thrombosis (DVT) and pulmonary embolism (PE), known collectively as venous thromboembolism (VTE), is approximately 900,000 (Geerts, et al, 2008). Approximately two-thirds of cases of DVT or PE are associated with recent hospitalization. This is consistent with the 2001 report by The Agency for Healthcare Research and Quality (AHRQ). AHRQ indicates that &quot;the appropriate application of effective preventive measures in hospitals has major potential for improving patient safety by reducing the incidence of venous thromboembolism&quot; (Shojania, 2001).

Despite its proven effectiveness, rates of appropriate thromboprophylaxis remain low in both medical and surgical patients. A recent analysis from the ENDORSE survey, which evaluated prophylaxis rates in 17,084 major surgery patients, found that more than one third of patients at risk for VTE (38%) did not receive prophylaxis and that rates varied by surgery type (Cohen, et al., 2008).

In a review of evidence-based patient safety practices, the Agency for Healthcare Research and Quality defined thromboprophylaxis against VTE as the &quot;number one patient safety practice&quot; for hospitalized patients (Shojania, 2001). Updated &quot;safe practices&quot; published by the National Quality Forum (NQF) recommend routine evaluation of hospitalized patients for risk of VTE and use of appropriate prophylaxis (National Quality Forum. National Voluntary Consensus Standards for Prevention and Care of Venous Thromboembolism, 2006).

As noted by the ACCP, a vast number of randomized clinical trials provide irrefutable evidence that thromboprophylaxis reduces VTE events, and there are studies that have also shown that fatal PE is prevented by thromboprophylaxis (Geerts, et al. 2008).

Some select surgeries have previously been monitored in the Surgical Care Improvement Project; since performance on these surgeries has achieved very high levels, they are not included in this measure."/>
  <clinicalRecommendationStatement
                                   value="Failure to recognize and protect patients at risk for venous thromboembolism (VTE) increases the chances for acutely ill hospitalized patients at high risk for developing a deep vein thrombosis or dying from a pulmonary emboli. Screening all patients is the only evidence based practice in reducing incidence of disease.  All hospitalized patients should be evaluated for primary VTE prophylaxis, and given appropriate prophylaxis when indicated."/>
  <improvementNotation>
    <coding>
      <system
              value="http://terminology.hl7.org/CodeSystem/measure-improvement-notation"/>
      <code value="increase"/>
      <display value="Increased score indicates improvement"/>
    </coding>
  </improvementNotation>
  <guidance
            value="When low dose unfractionated heparin is administered for VTE Prophylaxis, the intended administration route for low dose unfractionated heparin is subcutaneous.

Reasons for no pharmacological and no mechanical VTE prophylaxis must be explicitly documented by the MD/APN/PA or pharmacist and linked with VTE prophylaxis. Ambulation alone is not a sufficient reason for not administering VTE prophylaxis. In order for ambulation/patient ambulating to be considered as an acceptable reason, there needs to be explicit documentation, e.g., &quot;patient out of bed and ambulating in halls - no VTE prophylaxis needed.&quot;"/>
  <group id="group-1">
    <extension
               url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.group.linkId">
      <valueString value="primary"/>
    </extension>
    <population>
      <extension
                 url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.group.population.linkId">
        <valueString value="primary-exm108-initial-population"/>
      </extension>
      <code>
        <coding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/measure-population"/>
          <code value="initial-population"/>
          <display value="Initial Population"/>
        </coding>
      </code>
      <description
                   value="Patients age 18 and older discharged from hospital inpatient acute care without a diagnosis of venous thromboembolism (VTE) or obstetrics with a length of stay less than or equal to 120 days that ends during the measurement period"/>
      <criteria>
        <language value="text/cql-identifier"/>
        <expression value="Initial Population"/>
      </criteria>
    </population>
    <population>
      <extension
                 url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.group.population.linkId">
        <valueString value="primary-exm108-numerator"/>
      </extension>
      <code>
        <coding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/measure-population"/>
          <code value="numerator"/>
          <display value="Numerator"/>
        </coding>
      </code>
      <description
                   value="Patients who received VTE prophylaxis:
- the day of or the day after hospital admission
- the day of or the day after surgery end date for surgeries that end the day of or the day after hospital admission

Patients who have documentation of a reason why no VTE prophylaxis was given:
- between arrival and hospital admission
- the day of or the day after hospital admission
- the day of or the day after surgery end date (for surgeries that end the day of or the day after hospital admission)"/>
      <criteria>
        <language value="text/cql-identifier"/>
        <expression value="Numerator"/>
      </criteria>
    </population>
    <population>
      <extension
                 url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.group.population.linkId">
        <valueString value="primary-exm108-denominator"/>
      </extension>
      <code>
        <coding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/measure-population"/>
          <code value="denominator"/>
          <display value="Denominator"/>
        </coding>
      </code>
      <description value="All patients in the initial population"/>
      <criteria>
        <language value="text/cql-identifier"/>
        <expression value="Denominator"/>
      </criteria>
    </population>
    <population>
      <extension
                 url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.group.population.linkId">
        <valueString value="primary-exm108-denominator-exclusion"/>
      </extension>
      <code>
        <coding>
          <system
                  value="http://terminology.hl7.org/CodeSystem/measure-population"/>
          <code value="denominator-exclusion"/>
          <display value="Denominator Exclusion"/>
        </coding>
      </code>
      <description
                   value="* Patients who have a length of stay less than 2 days
* Patients with comfort measures documented anytime between arrival and the day after hospital admission
* Patients with comfort measures documented by the day after surgery end date for surgeries that start the day of or the day after hospital admission
* Patients who are direct admits to intensive care unit (ICU), or transferred to ICU the day of or the day after hospital admission with ICU length of stay greater than or equal to one day
* Patients with a principal diagnosis of mental disorders or stroke
* Patients with a principal procedure of Surgical Care Improvement Project (SCIP) VTE selected surgeries"/>
      <criteria>
        <language value="text/cql-identifier"/>
        <expression value="Denominator Exclusion"/>
      </criteria>
    </population>
  </group>
  <supplementalData>
    <extension
               url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.supplementalData.linkId">
      <valueString value="primary-sde-ethnicity"/>
    </extension>
    <extension
               url="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-includeInReportType">
      <valueCode value="summary"/>
    </extension>
    <usage>
      <coding>
        <system
                value="http://terminology.hl7.org/CodeSystem/measure-data-usage"/>
        <code value="supplemental-data"/>
      </coding>
    </usage>
    <criteria>
      <language value="text/cql-identifier"/>
      <expression value="SDE Ethnicity"/>
    </criteria>
  </supplementalData>
  <supplementalData>
    <extension
               url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.supplementalData.linkId">
      <valueString value="primary-sde-payer"/>
    </extension>
    <extension
               url="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-includeInReportType">
      <valueCode value="summary"/>
    </extension>
    <usage>
      <coding>
        <system
                value="http://terminology.hl7.org/CodeSystem/measure-data-usage"/>
        <code value="supplemental-data"/>
      </coding>
    </usage>
    <criteria>
      <language value="text/cql-identifier"/>
      <expression value="SDE Payer"/>
    </criteria>
  </supplementalData>
  <supplementalData>
    <extension
               url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.supplementalData.linkId">
      <valueString value="primary-sde-race"/>
    </extension>
    <extension
               url="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-includeInReportType">
      <valueCode value="summary"/>
    </extension>
    <usage>
      <coding>
        <system
                value="http://terminology.hl7.org/CodeSystem/measure-data-usage"/>
        <code value="supplemental-data"/>
      </coding>
    </usage>
    <criteria>
      <language value="text/cql-identifier"/>
      <expression value="SDE Race"/>
    </criteria>
  </supplementalData>
  <supplementalData>
    <extension
               url="http://hl7.org/fhir/5.0/StructureDefinition/extension-Measure.supplementalData.linkId">
      <valueString value="primary-sde-sex"/>
    </extension>
    <extension
               url="http://hl7.org/fhir/uv/cqm/StructureDefinition/cqm-includeInReportType">
      <valueCode value="summary"/>
    </extension>
    <usage>
      <coding>
        <system
                value="http://terminology.hl7.org/CodeSystem/measure-data-usage"/>
        <code value="supplemental-data"/>
      </coding>
    </usage>
    <criteria>
      <language value="text/cql-identifier"/>
      <expression value="SDE Sex"/>
    </criteria>
  </supplementalData>
</Measure>