dQM QICore Content Implementation Guide
2025.0.0 - CI Build
dQM QICore Content Implementation Guide, published by cqframework. This guide is not an authorized publication; it is the continuous build for version 2025.0.0 built by the FHIR (HL7® FHIR® Standard) CI Build. This version is based on the current content of https://github.com/cqframework/dqm-content-qicore-2025/ and changes regularly. See the Directory of published versions
Active as of 2025-08-25 |
{
"resourceType" : "Measure",
"id" : "CMS1244FHIRECATHOQR",
"meta" : {
"profile" : [
🔗 "http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-shareablemeasure"🔗 ,
"http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/computable-measure-cqfm"🔗 ,
"http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/publishable-measure-cqfm"🔗 ,
"http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/executable-measure-cqfm"🔗 ,
"http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cql-measure-cqfm"🔗 ,
"http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/elm-measure-cqfm"🔗 ,
"http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/proportion-measure-cqfm"
]
},
"text" : {
"status" : "extensions",
"div" : "<div xmlns=\"http://www.w3.org/1999/xhtml\" class=\"col-12\">\n <table class=\"narrative-table\">\n <tbody>\n<tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Metadata</th>\n\n\n</tr>\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Title</th>\n\n\n<td class=\"content-container\">Emergency Care Access & Timeliness (HOQR)FHIR</td>\n</tr>\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Version</th>\n\n\n<td class=\"content-container\">1.0.000</td>\n</tr>\n\n\n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Short Name</th>\n\n\n<td class=\"content-container\">CMS1244FHIR</td>\n</tr>\n\n\n\n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">GUID (Version Independent)</th>\n\n\n<td class=\"content-container\">urn:uuid:1d711504-ebec-41de-81b0-d1993115eac2</td>\n</tr>\n\n\n\n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">GUID (Version Specific)</th>\n\n\n<td class=\"content-container\">urn:uuid:43ee6832-7bc9-4247-a51c-6d8052f1a222</td>\n</tr>\n\n\n\n \n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">CMS Identifier</th>\n\n\n<td class=\"content-container\">1244FHIR</td>\n</tr>\n\n \n\n\n \n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">CMS Consensus Based Entity Identifier</th>\n\n\n<td class=\"content-container\">4625e</td>\n</tr>\n\n \n\n\n\n \n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Effective Period</th>\n\n\n<td class=\"content-container\">2027-01-01 through 2027-12-31</td>\n</tr>\n\n \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Steward (Publisher)</th>\n\n\n<td class=\"content-container\">Centers for Medicare & Medicaid Services (CMS)</td>\n</tr>\n\n\n\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Developer</th>\n\n\n<td class=\"content-container\">Acumen, LLC</td>\n</tr>\n\n\n\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Description</th>\n\n\n<td class=\"content-container\">This measure assesses the variation in access and timeliness of emergency care to support hospital quality improvement for patients requiring emergency care in an emergency department (ED). This measure is designed to align with incentives to promote improved care both in EDs and the broader health system to help identify where patients do not receive timely access to emergency care. Emergency care access and timeliness gaps are inclusive of several concepts pertaining to boarding and crowding in an ED, including significantly longer ED wait times, higher left without being seen rates, longer boarding times, and longer total length of stay in the ED.</td>\n</tr>\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Copyright</th>\n\n\n<td class=\"content-container\">Limited proprietary coding is contained in these specifications for user convenience. Users of proprietary code sets should obtain all necessary licenses from the owners of the code sets. This material contains SNOMED Clinical Terms(R) (SNOMED CT[R]) copyright 2004-2024 International Health Terminology Standards Development Organisation. All rights reserved. ICD-10 copyright 2024 World Health Organization. All Rights Reserved. CPT(R) contained in the Measure specifications is copyright 2004-2024 American Medical Association.</td>\n</tr>\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Disclaimer</th>\n\n\n<td class=\"content-container\">These performance specifications are not clinical guidelines, do not establish a standard of medical care, and have not been tested for all potential applications. THE MEASURES AND SPECIFICATIONS ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. Due to technical limitations, registered trademarks are indicated by (R) or [R] and unregistered trademarks are indicated by (TM) or [TM].</td>\n</tr>\n\n\n\n\n\n\n\n\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Rationale</th>\n\n\n<td class=\"content-container\">This measure aims to reduce patient harm and improve outcomes for patients requiring emergency care in an ED by addressing the variation in emergency care and measuring access and timeliness of emergency care. There are long-standing concerns about parameters that impact access and timeliness of care in the ED. Currently, there are no national metrics to assess the proportion of patients impacted by access and timeliness of ED care.</td>\n</tr>\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Clinical Recommendation Statement</th>\n\n\n<td class=\"content-container\">The goal of the Emergency Care Access & Timeliness (ECAT) measure is to assess and improve the safety of the 140 million ED visits that patients experience each year (Centers for Disease Control and Prevention [CDC], 2021). Limitations in access and timeliness of emergency care have been shown to be associated with harm, such as increases in mortality, delays in care, preventable errors, poor patient experience, and staff burnout. These quality limitations are also associated with increased costs of care. The ECAT measure under consideration is intended for use in CMS’s Hospital Outpatient Quality Reporting (HOQR) program. The numerator is comprised of all ED visits with a quality gap in access as defined in the numerator criteria. Challenges related to emergency care access and timeliness have been increasing and have prompted public calls for action. This measure improves upon previous efforts as it measures the mean instead of the median to highlight the presence of extreme quality gaps, and captures several indicators of quality gaps by using multiple numerator criteria. Implementation of this measure, which captures multiple components of access and timeliness, can help identify facilities where patients do not receive timely access to emergency care as defined in the numerator criteria. This measure, therefore, could positively impact millions of patients who seek treatment in the ED and help address long-standing disparities in emergency care, including for patients with mental health diagnoses.</td>\n</tr>\n\n\n\n\n<tr>\n \n \n \n \n\n<th scope=\"row\" class=\"row-header\">Citation</th>\n\n\n \n \n <td class=\"content-container\">\n \n \n \n American College of Emergency Physicians. (2018). Definition of Boarded Patient. Policy Statements. https://www.acep.org/patient-care/policy-statements/definition-of-boarded-patient\n \n \n \n \n \n </td>\n</tr>\n\n<tr>\n \n \n \n \n\n<th scope=\"row\" class=\"row-header\">Citation</th>\n\n\n \n \n <td class=\"content-container\">\n \n \n \n American Medical Association. (2022). What is Behavioral Health. https://www.ama-assn.org/delivering-care/public-health/what-behavioral-health\n \n \n \n \n \n </td>\n</tr>\n\n<tr>\n \n \n \n \n\n<th scope=\"row\" class=\"row-header\">Citation</th>\n\n\n \n \n <td class=\"content-container\">\n \n \n \n Centers for Disease Control and Prevention. (2021). Emergency Department Visits. https://www.cdc.gov/nchs/fastats/emergency-department.htm\n \n \n \n \n \n </td>\n</tr>\n\n<tr>\n \n \n \n \n\n<th scope=\"row\" class=\"row-header\">Citation</th>\n\n\n \n \n <td class=\"content-container\">\n \n \n \n eCQI Resource Center. (n.d). Median Admit Decision Time to ED Departure Time for Admitted Patients.\n \n \n \n \n \n </td>\n</tr>\n\n\n\n\n\n\n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Boarding: The practice of holding inpatients in the emergency department after admission to the hospital because no hospital inpatient bed is available. (American College of Emergency Physicians [ACEP], 2018).</td>\n</tr>\n\n\n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">ED Observation: Observation stays are inclusive of both ED observation care in which a patient initially evaluated in the ED is cared for under observation status for an extended period of time in the ED or in a care area dedicated to observation care, as well as hospital observation stays in which a patient initially evaluated in the ED is cared for in observation status often in a hospital bed used for both inpatient or observation status admissions. Because these two forms of observation stays cannot be easily distinguished in a standardized fashion in existing electronic health record data ontologies, for the purposes of this quality measure all observation stays have been considered an exclusion from both numerator criteria 3 and 4.</td>\n</tr>\n\n\n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Left Without Being Seen (LWBS): Patients arrive to the ED for evaluation and leave before seeing a physician, advanced practice nurse, or physician’s assistant.</td>\n</tr>\n\n\n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Mental Health: Mental health generally refers to mental health diagnoses, life stressors and crises, and stress-related physical symptoms (American Medical Association [AMA], 2022). For this measure, mental health conditions will be defined separately from substance use disorders.</td>\n</tr>\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Guidance (Usage)</th>\n\n\n<td class=\"content-container\"><p>Measure Score Calculation The measure score is first calculated at the individual ED level as the proportion of ED visits where any one of the four outcomes occurred, as defined by the numerator. Scores will be standardized z-scores by ED case volume strata (defined in ED visit volume bands of 20,000 visits). For CMS Certification Numbers (CCNs) with more than one ED, volume-adjusted z-scores are then combined as a weighted average for that CCN. A z-score of greater than zero means worse performance and less than zero means better performance, compared to like EDs. For the purposes of this measure, a decision to admit can be captured using any of the following: - an evaluation that results in a decision to admit - an order to admit to inpatient - an order for a bed assignment - start of inpatient admission This dQM is an episode-based measure. An episode is defined as an ED visit that ends during the measurement period. This FHIR-based measure has been derived from the QDM-based measure: CMS1244v1. Please refer to the HL7 QI-Core Implementation Guide (<em><u>https://hl7.org/fhir/us/qicore/STU6/</u></em>) for more information on QI-Core and mapping recommendations from QDM to QI-Core STU 6 (<em><u>https://hl7.org/fhir/us/qicore/STU6/qdm-to-qicore.html</u></em>).</p></td>\n</tr>\n\n\n\n \n \n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Measure Group (Rate) (ID: Group_1)</th>\n\n\n</tr>\n \n \n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Basis</th>\n\n\n<td class=\"content-container\">Encounter</td>\n</tr>\n\n\n\n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Scoring</th>\n\n\n<td class=\"content-container\">[http://terminology.hl7.org/CodeSystem/measure-scoring#proportion: 'Proportion']</td>\n</tr>\n\n\n\n\n\n\n\n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Type</th>\n\n\n<td class=\"content-container\">[http://terminology.hl7.org/CodeSystem/measure-type#outcome: 'Outcome']</td>\n</tr>\n\n\n\n\n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Rate Aggregation</th>\n\n\n<td class=\"content-container\">None</td>\n</tr>\n\n\n\n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Improvement Notation</th>\n\n\n<td class=\"content-container\">[http://terminology.hl7.org/CodeSystem/measure-improvement-notation#decrease: 'Decreased score indicates improvement']</td>\n</tr>\n\n\n \n \n <tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Initial Population</th>\n\n\n \n <td class=\"content-container\">\n \n <em>ID</em>: InitialPopulation_1\n <br/>\n \n \n <em>Description</em>:\n <p style=\"white-space: pre-line\" class=\"tab-one\">All ED visits that end during the measurement period for all patients</p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms1244fhirecathoqr-initial-population\">Initial Population</a> \n \n \n </td>\n </tr>\n \n\n \n <tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Denominator</th>\n\n\n \n <td class=\"content-container\">\n \n <em>ID</em>: Denominator_1\n <br/>\n \n \n <em>Description</em>:\n <p style=\"white-space: pre-line\" class=\"tab-one\">Equals Initial Population</p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms1244fhirecathoqr-denominator\">Denominator</a> \n \n \n </td>\n </tr>\n \n\n \n <tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Numerator</th>\n\n\n \n <td class=\"content-container\">\n \n <em>ID</em>: Numerator_1\n <br/>\n \n \n <em>Description</em>:\n <p style=\"white-space: pre-line\" class=\"tab-one\">The numerator is comprised of ED visits meeting the denominator criteria and where the patient experiences any of the following quality gaps in access: 1. The patient waited longer than 60 minutes (1 hour) after arrival to the ED to be placed in a treatment room or dedicated treatment area that allows for audiovisual privacy during history-taking and physical examination, or 2. The patient left the ED without being evaluated, or 3. The patient boarded (time from Decision to Admit order to ED departure for admitted patients) in the ED for longer than 240 minutes (4 hours), or 4. The patient had an ED length of stay (LOS) (time from ED arrival to ED departure as defined by the ED departure timestamp indicating when the patient physically left the ED) of longer than 480 minutes (8 hours). ED encounters with ED observation stays are excluded from criteria #3 (boarding) and #4 (ED LOS). To clarify, patients who have a ‘decision to admit’ after an ED observation stay remain excluded from criteria #3 (boarded) calculations.</p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms1244fhirecathoqr-numerator\">Numerator</a> \n \n \n </td>\n </tr>\n \n\n \n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Stratifier</th>\n\n\n <td class=\"content-container\">\n \n <em>ID</em>: Stratification_1_1\n \n <br/>\n \n \n \n \n <em>Description</em>: All patients aged less than 18 years seen in the ED who do not have an ED encounter principal diagnosis consistent with mental health diagnosis. Patients who have an ED encounter principal diagnosis consistent with substance use disorders will be included in this stratification.\n \n </td>\n</tr>\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Stratifier</th>\n\n\n <td class=\"content-container\">\n \n <em>ID</em>: Stratification_1_2\n \n <br/>\n \n \n \n \n <em>Description</em>: All patients aged 18 years and older seen in the ED who do not have an ED encounter principal diagnosis consistent with mental health diagnosis. Patients who have an ED encounter principal diagnosis consistent with substance use disorders will be included in this stratification.\n \n </td>\n</tr>\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Stratifier</th>\n\n\n <td class=\"content-container\">\n \n <em>ID</em>: Stratification_1_3\n \n <br/>\n \n \n \n \n <em>Description</em>: All patients aged less than 18 years seen in the ED who have an ED encounter principal diagnosis consistent with mental health diagnosis.\n \n </td>\n</tr>\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Stratifier</th>\n\n\n <td class=\"content-container\">\n \n <em>ID</em>: Stratification_1_4\n \n <br/>\n \n \n \n \n <em>Description</em>: All patients aged 18 years and older seen in the ED who have an ED encounter principal diagnosis consistent with mental health diagnosis.\n \n </td>\n</tr>\n\n\n\n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Supplemental Data Guidance</th>\n\n\n<td class=\"content-container\">For every patient evaluated by this measure also identify payer, race, ethnicity and sex</td>\n</tr>\n\n \n\n\n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Supplemental Data Elements</th>\n\n\n</tr>\n\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Supplemental Data Element</th>\n\n\n <td class=\"content-container\">\n \n <em>ID</em>: sde-ethnicity\n \n <br/>\n \n \n \n \n \n <em>Usage Code</em>: [http://terminology.hl7.org/CodeSystem/measure-data-usage#supplemental-data]\n \n <br/>\n \n \n \n <em>Description</em>: SDE Ethnicity\n \n \n \n <br/>\n \n <em>Logic Definition</em>: <a href=\"#cms1244fhirecathoqr-sde-ethnicity\">SDE Ethnicity</a> \n \n \n </td>\n</tr>\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Supplemental Data Element</th>\n\n\n <td class=\"content-container\">\n \n <em>ID</em>: sde-payer\n \n <br/>\n \n \n \n \n \n <em>Usage Code</em>: [http://terminology.hl7.org/CodeSystem/measure-data-usage#supplemental-data]\n \n <br/>\n \n \n \n <em>Description</em>: SDE Payer\n \n \n \n <br/>\n \n <em>Logic Definition</em>: <a href=\"#cms1244fhirecathoqr-sde-payer\">SDE Payer</a> \n \n \n </td>\n</tr>\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Supplemental Data Element</th>\n\n\n <td class=\"content-container\">\n \n <em>ID</em>: sde-race\n \n <br/>\n \n \n \n \n \n <em>Usage Code</em>: [http://terminology.hl7.org/CodeSystem/measure-data-usage#supplemental-data]\n \n <br/>\n \n \n \n <em>Description</em>: SDE Race\n \n \n \n <br/>\n \n <em>Logic Definition</em>: <a href=\"#cms1244fhirecathoqr-sde-race\">SDE Race</a> \n \n \n </td>\n</tr>\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Supplemental Data Element</th>\n\n\n <td class=\"content-container\">\n \n <em>ID</em>: sde-sex\n \n <br/>\n \n \n \n \n \n <em>Usage Code</em>: [http://terminology.hl7.org/CodeSystem/measure-data-usage#supplemental-data]\n \n <br/>\n \n \n \n <em>Description</em>: SDE Sex\n \n \n \n <br/>\n \n <em>Logic Definition</em>: <a href=\"#cms1244fhirecathoqr-sde-sex\">SDE Sex</a> \n \n \n </td>\n</tr>\n\n\n<tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Measure Logic</th>\n\n\n</tr>\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Primary Library</th>\n\n\n<td class=\"content-container\">https://madie.cms.gov/Library/CMS1244FHIRECATHOQR</td>\n</tr>\n\n\n\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Contents</th>\n <td class=\"content-container\">\n <em><a href=\"#population-criteria\">Population Criteria</a></em>\n <br/>\n <em><a href=\"#definitions\">Logic Definitions</a></em>\n <br/>\n <em><a href=\"#terminology\">Terminology</a></em>\n <br/>\n <em><a href=\"#dependencies\">Dependencies</a></em>\n <br/>\n <em><a href=\"#data-requirements\">Data Requirements</a></em>\n <br/>\n </td>\n</tr>\n\n\n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"population-criteria\"> </a>Population Criteria</th>\n\n\n</tr>\n \n \n \n \n \n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Measure Group (Rate) (ID: Group_1)</th>\n\n\n</tr>\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms1244fhirecathoqr-initial-population\"> </a>\n \n \n Initial Population\n \n </th>\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Initial Population":\n "ED Evaluation and Management"\n union "ED Triage Excluding Those Prior To ED Encounters"</code></pre>\n </td>\n\n</tr>\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms1244fhirecathoqr-denominator\"> </a>\n \n \n Denominator\n \n </th>\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Denominator":\n "Initial Population"</code></pre>\n </td>\n\n</tr>\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms1244fhirecathoqr-numerator\"> </a>\n \n \n Numerator\n \n </th>\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Numerator":\n "Time to Treatment Room Greater Than 60 Minutes"\n union "ED Arrival Left Without Being Seen"\n union "Boarded Time Greater Than 240 Minutes and No Observation Stay"\n union "ED Length of Stay Greater Than 480 Minutes and No Observation Stay"</code></pre>\n </td>\n\n</tr>\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms1244fhirecathoqr-stratification-1\"> </a>\n \n \n Stratifier\n \n </th>\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Stratification 1":\n "Pediatric With No Mental Health Diagnosis"</code></pre>\n </td>\n\n</tr>\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms1244fhirecathoqr-stratification-2\"> </a>\n \n \n Stratifier\n \n </th>\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Stratification 2":\n "Adult With No Mental Health Diagnosis"</code></pre>\n </td>\n\n</tr>\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms1244fhirecathoqr-stratification-3\"> </a>\n \n \n Stratifier\n \n </th>\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Stratification 3":\n "Pediatric With Mental Health Diagnosis"</code></pre>\n </td>\n\n</tr>\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms1244fhirecathoqr-stratification-4\"> </a>\n \n \n Stratifier\n \n </th>\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Stratification 4":\n "Adult With Mental Health Diagnosis"</code></pre>\n </td>\n\n</tr>\n\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n\n \n\n \n \n\n\n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"definitions\"> </a>Logic Definitions</th>\n\n\n</tr>\n \n \n \n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"supplementaldataelements-sde-sex\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> SupplementalDataElements</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "SDE Sex":\n case\n when Patient.sex = '248153007' then "Male (finding)"\n when Patient.sex = '248152002' then "Female (finding)"\n else null\n end</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"supplementaldataelements-sde-payer\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> SupplementalDataElements</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "SDE Payer":\n [Coverage: type in "Payer Type"] Payer\n return {\n code: Payer.type,\n period: Payer.period\n }</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"supplementaldataelements-sde-ethnicity\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> SupplementalDataElements</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "SDE Ethnicity":\n Patient.ethnicity E\n return Tuple {\n codes: { E.ombCategory } union E.detailed,\n display: E.text\n }</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"supplementaldataelements-sde-race\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> SupplementalDataElements</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "SDE Race":\n Patient.race R\n return Tuple {\n codes: R.ombCategory union R.detailed,\n display: R.text\n }</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n\n \n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"fhirhelpers-tostring\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> FHIRHelpers</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define function ToString(value uri): value.value</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"fhirhelpers-tointerval\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> FHIRHelpers</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Converts the given [Period](https://hl7.org/fhir/datatypes.html#Period)\nvalue to a CQL DateTime Interval\n@comment: If the start value of the given period is unspecified, the starting\nboundary of the resulting interval will be open (meaning the start of the interval\nis unknown, as opposed to interpreted as the beginning of time).\n*/\ndefine function ToInterval(period FHIR.Period):\n if period is null then\n null\n else\n if period."start" is null then\n Interval(period."start".value, period."end".value]\n else\n Interval[period."start".value, period."end".value]</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"fhirhelpers-toconcept\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> FHIRHelpers</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Converts the given FHIR [CodeableConcept](https://hl7.org/fhir/datatypes.html#CodeableConcept) value to a CQL Concept.\n*/\ndefine function ToConcept(concept FHIR.CodeableConcept):\n if concept is null then\n null\n else\n System.Concept {\n codes: concept.coding C return ToCode(C),\n display: concept.text.value\n }</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"fhirhelpers-tocode\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> FHIRHelpers</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Converts the given FHIR [Coding](https://hl7.org/fhir/datatypes.html#Coding) value to a CQL Code.\n*/\ndefine function ToCode(coding FHIR.Coding):\n if coding is null then\n null\n else\n System.Code {\n code: coding.code.value,\n system: coding.system.value,\n version: coding.version.value,\n display: coding.display.value\n }</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n\n \n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-sde-sex\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "SDE Sex":\n SDE."SDE Sex"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-evaluation-and-management\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Evaluation and Management":\n [Encounter: "Emergency Department Evaluation and Management Visit"] EDEvalManagementVisit\n where EDEvalManagementVisit.period ends during day of "Measurement Period"\n and EDEvalManagementVisit.status = 'finished'</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-triage\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Triage":\n ( [Encounter: "Triage"] EDTriage\n where EDTriage.period ends during day of "Measurement Period"\n and EDTriage.status in { 'finished', 'triaged' }\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-triage-excluding-those-prior-to-ed-encounters\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Triage Excluding Those Prior To ED Encounters":\n "ED Triage" EDTriageinMP\n where not exists ( "ED Evaluation and Management" EDEvalManagementInMP\n where ( ( EDTriageinMP.period overlaps before EDEvalManagementInMP.period )\n or ( EDTriageinMP.period during EDEvalManagementInMP.period )\n or ( EDEvalManagementInMP.period during EDTriageinMP.period )\n or ( EDTriageinMP.period ends 120 minutes or less before start of EDEvalManagementInMP.period )\n )\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-initial-population\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Initial Population":\n "ED Evaluation and Management"\n union "ED Triage Excluding Those Prior To ED Encounters"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-denominator\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Denominator":\n "Initial Population"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-triage-before-evaluation-management\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Triage Before Evaluation Management":\n "ED Triage" EDTriageinMP\n with "Denominator" EDEncounter\n such that ( ( EDTriageinMP.period overlaps before EDEncounter.period )\n or ( EDTriageinMP.period during EDEncounter.period )\n or ( EDEncounter.period during EDTriageinMP.period )\n or ( EDTriageinMP.period ends 120 minutes or less before start of EDEncounter.period )\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-triage-and-evaluation-management\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Triage and Evaluation Management":\n "Denominator"\n union "ED Triage Before Evaluation Management"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-time-to-treatment-room-greater-than-60-minutes\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Time to Treatment Room Greater Than 60 Minutes":\n "ED Evaluation and Management" EDEvalManagementInMP\n where EDEvalManagementInMP.edArrivalTime ( ) 61 minutes or more before EDEvalManagementInMP.edTreatmentRoomTimeArrivalTime ( )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-arrival-left-without-being-seen\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Arrival Left Without Being Seen":\n "Denominator" EDEncounter\n where EDEncounter.hospitalization.dischargeDisposition ~ "Patient left without being seen (finding)"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-to-inpatient-order\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED To Inpatient Order":\n [ServiceRequest: "Decision to Admit to Hospital Inpatient"] AdmitIPOrder\n where AdmitIPOrder.status in { 'active', 'completed' }</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-decision-to-admit-encounter-order\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Decision to Admit Encounter Order":\n "Denominator" EDEncounter\n with CQMCommon."Inpatient Encounter" EncounterInpatient\n such that EncounterInpatient.admitDecisionUsingEncounterOrder ( ) 241 minutes or more before EDEncounter.edDepartureTime ( )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-assessment-in-ed\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Assessment In ED":\n ["ObservationClinicalResult": "Emergency Department Evaluation"]\n union ["SimpleObservation": "Emergency Department Evaluation"] ObsInED\n where ObsInED.value as Concept in "Admit Inpatient"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-decision-to-admit-using-assessment\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Decision to Admit Using Assessment":\n "Denominator" EDEncounter\n with CQMCommon."Inpatient Encounter" EncounterInpatient\n such that EncounterInpatient.admitDecisionUsingAssessment ( ) 241 minutes or more before EDEncounter.edDepartureTime ( )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-inpatient-or-bed-assignment-encounter-order\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Inpatient Or Bed Assignment Encounter Order":\n ( [ServiceRequest: "Encounter Inpatient"]\n union [ServiceRequest: "Patient bed assigned (finding)"] ) IPRequest\n where IPRequest.status in { 'active', 'completed' }</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-time-of-admit-order-or-bed-assignment-to-departure-greater-than-241-minutes\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Time of Admit Order Or Bed Assignment to Departure Greater Than 241 Minutes":\n "Denominator" EDEncounter\n with CQMCommon."Inpatient Encounter" InpatientEncounter\n such that InpatientEncounter.admitInpatientOrBedAssignmentEncounterOrder ( ) 241 minutes or more before EDEncounter.edDepartureTime ( )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-admitted-to-inpatient-241-minutes-or-more-before-departure\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Admitted to Inpatient 241 Minutes or More Before Departure":\n "Denominator" EDEncounter\n with CQMCommon."Inpatient Encounter" Inpatient\n such that Inpatient.holdingInEDAfterAdmission ( ) 241 minutes or more before EDEncounter.edDepartureTime ( )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-boarded-time-greater-than-240-minutes\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Boarded Time Greater Than 240 Minutes":\n "Decision to Admit Encounter Order"\n union "Decision to Admit Using Assessment"\n union "Time of Admit Order Or Bed Assignment to Departure Greater Than 241 Minutes"\n union "Admitted to Inpatient 241 Minutes or More Before Departure"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-observation-status\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Observation Status":\n [Encounter: "Observation Services"] EDObsEncounter\n with "Denominator" EDEncounter\n such that EDObsEncounter.period during EDEncounter.period\n and EDObsEncounter.status = 'finished'</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-boarded-time-greater-than-240-minutes-and-no-observation-stay\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Boarded Time Greater Than 240 Minutes and No Observation Stay":\n ( "Boarded Time Greater Than 240 Minutes" Boarding\n where not exists ( "ED Observation Status" EDObs\n where ( EDObs.period during Boarding.period )\n )\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-length-of-stay-greater-than-480-minutes\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Length of Stay Greater Than 480 Minutes":\n "Denominator" EDEncounter\n where EDEncounter.edArrivalTime ( ) 481 minutes or more before EDEncounter.edDepartureTime ( )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-length-of-stay-greater-than-480-minutes-and-no-observation-stay\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Length of Stay Greater Than 480 Minutes and No Observation Stay":\n ( "ED Length of Stay Greater Than 480 Minutes" EDStay\n where not exists ( "ED Observation Status" EDObs\n where ( EDObs.period during EDStay.period )\n )\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-numerator\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Numerator":\n "Time to Treatment Room Greater Than 60 Minutes"\n union "ED Arrival Left Without Being Seen"\n union "Boarded Time Greater Than 240 Minutes and No Observation Stay"\n union "ED Length of Stay Greater Than 480 Minutes and No Observation Stay"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-encounter-or-triage-of-patients-18-years-and-older\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Encounter or Triage of Patients 18 Years and Older":\n "Denominator" EDEncounter\n where AgeInYearsAt(date from start of "Measurement Period") >= 18</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-adult-with-mental-health-diagnosis\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Adult With Mental Health Diagnosis":\n ( "ED Encounter or Triage of Patients 18 Years and Older" AdultEDEncounters\n where ( AdultEDEncounters.hasPrincipalDiagnosisOf ( "Mental Health Diagnosis without Substance Use Disorders" ) )\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-stratification-4\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Stratification 4":\n "Adult With Mental Health Diagnosis"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-ed-encounter-or-triage-of-patients-less-than-18-years\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "ED Encounter or Triage of Patients Less Than 18 Years":\n "Denominator" EDEncounter\n where AgeInYearsAt(date from start of "Measurement Period") < 18</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-pediatric-with-mental-health-diagnosis\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Pediatric With Mental Health Diagnosis":\n ( "ED Encounter or Triage of Patients Less Than 18 Years" PediatricEDEncounters\n where ( PediatricEDEncounters.hasPrincipalDiagnosisOf ( "Mental Health Diagnosis without Substance Use Disorders" ) )\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-stratification-3\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Stratification 3":\n "Pediatric With Mental Health Diagnosis"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-adult-with-no-mental-health-diagnosis\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Adult With No Mental Health Diagnosis":\n ( "ED Encounter or Triage of Patients 18 Years and Older" AdultEDEncounters\n where not ( AdultEDEncounters.hasPrincipalDiagnosisOf ( "Mental Health Diagnosis without Substance Use Disorders" ) )\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-stratification-2\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Stratification 2":\n "Adult With No Mental Health Diagnosis"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-pediatric-with-no-mental-health-diagnosis\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Pediatric With No Mental Health Diagnosis":\n ( "ED Encounter or Triage of Patients Less Than 18 Years" PediatricEDEncounters\n where not ( PediatricEDEncounters.hasPrincipalDiagnosisOf ( "Mental Health Diagnosis without Substance Use Disorders" ) )\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-stratification-1\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Stratification 1":\n "Pediatric With No Mental Health Diagnosis"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-sde-payer\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "SDE Payer":\n SDE."SDE Payer"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-sde-ethnicity\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "SDE Ethnicity":\n SDE."SDE Ethnicity"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-sde-race\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "SDE Race":\n SDE."SDE Race"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-edarrivaltime\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function "edArrivalTime"(EDEncounter Encounter):\n Last("ED Triage and Evaluation Management".location Location\n where exists((Location.location.getLocation().type) LocationType\n where(LocationType in "Emergency Department Location"\n or LocationType ~ "Emergency room"\n or LocationType ~ "Emergency trauma unit"\n )\n )\n and start of Location.period is not null\n and(Location.period ends 120 minutes or less before start of EDEncounter.period\n or Location.period overlaps before EDEncounter.period\n or EDEncounter.period overlaps before Location.period\n or Location.period starts same as start of EDEncounter.period\n )\n return start of Location.period\n sort ascending\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-edtreatmentroomtimearrivaltime\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function "edTreatmentRoomTimeArrivalTime"(EDEncounter Encounter):\n First(EDEncounter.location Location\n where Location.location.getLocation().type in "Emergency Department Treatment Location"\n and start of Location.period is not null\n return start of Location.period\n sort ascending\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-admitdecisionusingencounterorder\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function "admitDecisionUsingEncounterOrder"(EncounterInpatient Encounter):\n Last("ED To Inpatient Order" AdmitOrder\n let LastEDVisit: EncounterInpatient.lastEDEncounter()\n where AdmitOrder.authoredOn during LastEDVisit.period\n and AdmitOrder.intent ~ 'order'\n return AdmitOrder.authoredOn\n sort ascending\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-lastedencounter\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function "lastEDEncounter"(EncounterInpatient Encounter):\n Last("ED Evaluation and Management" EDEvalManagementInMP\n where EDEvalManagementInMP.period starts 1 day or less before or on start of EncounterInpatient.period\n and EDEvalManagementInMP.period starts before start of EncounterInpatient.period\n and EDEvalManagementInMP.period during day of "Measurement Period"\n and EDEvalManagementInMP.status = 'finished'\n sort by \n end of period ascending\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-eddeparturetime\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function "edDepartureTime"(EDEncounter Encounter):\n Last("ED Triage and Evaluation Management".location Location\n where exists((Location.location.getLocation().type) LocationType\n where(LocationType in "Emergency Department Location"\n or LocationType ~ "Emergency room"\n or LocationType ~ "Emergency trauma unit"\n )\n )\n and \n end of Location.period is not null\n and(Location.period ends 120 minutes or less before start of EDEncounter.period\n or Location.period overlaps before EDEncounter.period\n or EDEncounter.period overlaps before Location.period\n or Location.period starts same as start of EDEncounter.period\n )\n return \n end of Location.period\n sort ascending\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-admitdecisionusingassessment\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function "admitDecisionUsingAssessment"(EncounterInpatient Encounter):\n Last("Assessment In ED" EDEvaluation\n let LastEDVisit: EncounterInpatient.lastEDEncounter()\n where EDEvaluation.effective.toInterval() starts during LastEDVisit.period\n and EDEvaluation.status in { 'final', 'amended', 'corrected' }\n return start of EDEvaluation.effective.toInterval()\n sort ascending\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-admitinpatientorbedassignmentencounterorder\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function "admitInpatientOrBedAssignmentEncounterOrder"(Encounter Encounter):\n Last(("Inpatient Or Bed Assignment Encounter Order") AdmitInpatientOrder\n let LastEDVisit: Encounter.lastEDEncounter()\n where AdmitInpatientOrder.authoredOn during LastEDVisit.period\n return AdmitInpatientOrder.authoredOn\n sort ascending\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms1244fhirecathoqr-holdinginedafteradmission\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS1244FHIRECATHOQR</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function holdingInEDAfterAdmission(InpatientEncounter Encounter):\n Last(CQMCommon."Inpatient Encounter" AdmittedInpatient\n let LastEDVisit: InpatientEncounter.lastEDEncounter()\n where start of AdmittedInpatient.period during LastEDVisit.period\n return start of AdmittedInpatient.period\n sort ascending\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n\n \n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cqmcommon-inpatient-encounter\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define "Inpatient Encounter":\n [Encounter: "Encounter Inpatient"] EncounterInpatient\n where EncounterInpatient.status = 'finished'\n and EncounterInpatient.period ends during day of "Measurement Period"</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cqmcommon-getlocation\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns the Location resource specified by the given reference.\n*/\ndefine fluent function getLocation(reference Reference):\n singleton from (\n [Location] L where reference.references(L)\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cqmcommon-hasprincipaldiagnosisof\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n @description: Returns the condition that is specified as the principal diagnosis for the encounter and has a code in the given valueSet.\n @comment: See the QICore 6 Authoring Patterns discussion on [Principal Diagnosis and Present on Admission](https://github.com/cqframework/CQL-Formatting-and-Usage-Wiki/wiki/Authoring-Patterns-QICore-v6.0.0#conditions-present-on-admission-and-principal-diagnoses) for more information\n */\n define fluent function hasPrincipalDiagnosisOf(encounter Encounter, valueSet ValueSet):\n (encounter.principalDiagnosis()) PD\n return PD.diagnosis in valueSet\n or PD.diagnosis.getCondition().code in valueSet</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cqmcommon-principaldiagnosis\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns the claim diagnosis element that is specified as the principal diagnosis for the encounter\n @comment: See the QICore 6 Authoring Patterns discussion on [Principal Diagnosis and Present on Admission](https://github.com/cqframework/CQL-Formatting-and-Usage-Wiki/wiki/Authoring-Patterns-QICore-v6.0.0#conditions-present-on-admission-and-principal-diagnoses) for more information\n*/\ndefine fluent function principalDiagnosis(encounter Encounter):\nsingleton from (\n (encounter.claimDiagnosis()) CD\n where CD.type.includesCode("Principal Diagnosis")\n )</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cqmcommon-claimdiagnosis\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns the claim diagnosis elements for the given encounter\n@comment: See the QICore 6 Authoring Patterns discussion on [Principal Diagnosis and Present on Admission](https://github.com/cqframework/CQL-Formatting-and-Usage-Wiki/wiki/Authoring-Patterns-QICore-v6.0.0#conditions-present-on-admission-and-principal-diagnoses) for more information\n*/\ndefine fluent function claimDiagnosis(encounter Encounter):\n encounter E\n let \n claim: ([Claim] C where C.status = 'active' and C.use = 'claim' and exists (C.item I where I.encounter.references(E))),\n claimItem: (claim.item I where I.encounter.references(E))\n return claim.diagnosis D where D.sequence in claimItem.diagnosisSequence</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cqmcommon-getcondition\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns the Condition resource for the given reference\n*/\ndefine fluent function getCondition(reference Reference):\n singleton from (([ConditionEncounterDiagnosis] union [ConditionProblemsHealthConcerns]) C where reference.references(C.id))</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n\n \n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"qicorecommon-references\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> QICoreCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns true if the given reference is to the given resource\n@comment: Returns true if the `id` element of the given resource exactly equals the tail of the given reference.\nNOTE: This function assumes resources from the same source server.\n*/\ndefine fluent function references(reference Reference, resource Resource):\n resource.id = Last(Split(reference.reference, '/'))</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"qicorecommon-references\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> QICoreCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns true if any of the given references are to the given resource\n@comment: Returns true if the `id` element of the given resource exactly equals the tail of any of the given references.\nNOTE: This function assumes resources from the same source server.\n*/\ndefine fluent function references(references List<Reference>, resource Resource):\n exists (references R where R.references(resource))</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"qicorecommon-includescode\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> QICoreCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns true if the given code is in the given codeList\n@comment: Returns true if the `code` is equivalent to any of the codes in the given `codeList`, false otherwise.\n*/\ndefine fluent function includesCode(codeList List<Concept>, code Code):\n exists (codeList C where C ~ code)</code></pre>\n </td>\n\n</tr>\n\n\n\n \n\n\n\n \n\n\n<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"qicorecommon-references\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> QICoreCommon</td>\n\n</tr>\n<tr>\n\n <td>\n <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns true if the given reference is to the given resourceId\n@comment: Returns true if the `resourceId` parameter exactly equals the tail of the given reference.\nNOTE: This function assumes resources from the same source server.\n*/\ndefine fluent function references(reference Reference, resourceId String):\n resourceId = Last(Split(reference.reference, '/'))</code></pre>\n </td>\n\n</tr>\n\n\n\n\n\n \n \n\n\n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"terminology\"> </a>Terminology</th>\n\n\n</tr>\n \n \n \n\n \n\n \n\n \n\n \n\n \n\n\n<tr>\n \n \n \n\n<th scope=\"row\" class=\"row-header\">Code System</th>\n\n\n \n <td class=\"content-container\">\n \n <em>Description</em>: Code system SNOMEDCT\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://snomed.info/sct\n <br/>\n <em>Canonical URL</em>: <tt>http://snomed.info/sct</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n \n\n<th scope=\"row\" class=\"row-header\">Code System</th>\n\n\n \n <td class=\"content-container\">\n \n <em>Description</em>: Code system RoleCode\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://terminology.hl7.org/CodeSystem/v3-RoleCode\n <br/>\n <em>Canonical URL</em>: <tt>http://terminology.hl7.org/CodeSystem/v3-RoleCode</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n \n\n<th scope=\"row\" class=\"row-header\">Code System</th>\n\n\n \n <td class=\"content-container\">\n \n <em>Description</em>: Code system Diagnosis Type\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://terminology.hl7.org/CodeSystem/ex-diagnosistype\n <br/>\n <em>Canonical URL</em>: <tt>http://terminology.hl7.org/CodeSystem/ex-diagnosistype</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Emergency Department Evaluation and Management Visit\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1010\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1010</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Triage\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.279\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.279</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Emergency Department Location\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.284\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.284</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Emergency Department Treatment Location\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.278\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.278</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Encounter Inpatient\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Decision to Admit to Hospital Inpatient\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.294\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.294</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Emergency Department Evaluation\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.163\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.163</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Admit Inpatient\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.164\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.164</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Observation Services\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Mental Health Diagnosis without Substance Use Disorders\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.285\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.285</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n \n \n <td class=\"content-container\">\n \n <em>Description</em>: Value set Payer Type\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591</tt>\n \n </td>\n</tr>\n \n\n\n \n <tr>\n <th scope=\"row\" class=\"row-header\">Direct Reference Code</th>\n <td class=\"content-container\">\n \n <em>Display</em>: Male (finding)\n <br/>\n \n <em>Code</em>: 248153007\n <br/>\n <em>System</em>: <tt>http://snomed.info/sct</tt>\n </td>\n </tr>\n\n <tr>\n <th scope=\"row\" class=\"row-header\">Direct Reference Code</th>\n <td class=\"content-container\">\n \n <em>Display</em>: Female (finding)\n <br/>\n \n <em>Code</em>: 248152002\n <br/>\n <em>System</em>: <tt>http://snomed.info/sct</tt>\n </td>\n </tr>\n\n <tr>\n <th scope=\"row\" class=\"row-header\">Direct Reference Code</th>\n <td class=\"content-container\">\n \n <em>Display</em>: Emergency room\n <br/>\n \n <em>Code</em>: ER\n <br/>\n <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/v3-RoleCode</tt>\n </td>\n </tr>\n\n <tr>\n <th scope=\"row\" class=\"row-header\">Direct Reference Code</th>\n <td class=\"content-container\">\n \n <em>Display</em>: Emergency trauma unit\n <br/>\n \n <em>Code</em>: ETU\n <br/>\n <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/v3-RoleCode</tt>\n </td>\n </tr>\n\n <tr>\n <th scope=\"row\" class=\"row-header\">Direct Reference Code</th>\n <td class=\"content-container\">\n \n <em>Display</em>: Patient left without being seen (finding)\n <br/>\n \n <em>Code</em>: 21541000119102\n <br/>\n <em>System</em>: <tt>http://snomed.info/sct</tt>\n </td>\n </tr>\n\n <tr>\n <th scope=\"row\" class=\"row-header\">Direct Reference Code</th>\n <td class=\"content-container\">\n \n <em>Display</em>: Patient bed assigned (finding)\n <br/>\n \n <em>Code</em>: 5751000175101\n <br/>\n <em>System</em>: <tt>http://snomed.info/sct</tt>\n </td>\n </tr>\n\n <tr>\n <th scope=\"row\" class=\"row-header\">Direct Reference Code</th>\n <td class=\"content-container\">\n \n <em>Display</em>: Principal Diagnosis\n <br/>\n \n <em>Code</em>: principal\n <br/>\n <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/ex-diagnosistype</tt>\n </td>\n </tr>\n\n \n \n\n\n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"dependencies\"> </a>Dependencies</th>\n\n\n</tr>\n \n \n \n\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Dependency</th>\n\n\n <td class=\"content-container\">\n \n <em>Description</em>: QICore model information\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://hl7.org/fhir/Library/QICore-ModelInfo\n <br/>\n <em>Canonical URL</em>: <tt>http://hl7.org/fhir/Library/QICore-ModelInfo</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Dependency</th>\n\n\n <td class=\"content-container\">\n \n <em>Description</em>: Library SDE\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: https://madie.cms.gov/Library/SupplementalDataElements|5.1.000\n <br/>\n <em>Canonical URL</em>: <tt>https://madie.cms.gov/Library/SupplementalDataElements|5.1.000</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Dependency</th>\n\n\n <td class=\"content-container\">\n \n <em>Description</em>: Library FHIRHelpers\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: https://madie.cms.gov/Library/FHIRHelpers|4.4.000\n <br/>\n <em>Canonical URL</em>: <tt>https://madie.cms.gov/Library/FHIRHelpers|4.4.000</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Dependency</th>\n\n\n <td class=\"content-container\">\n \n <em>Description</em>: Library CQMCommon\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: https://madie.cms.gov/Library/CQMCommon|4.1.000\n <br/>\n <em>Canonical URL</em>: <tt>https://madie.cms.gov/Library/CQMCommon|4.1.000</tt>\n \n </td>\n</tr>\n \n\n\n<tr>\n \n\n<th scope=\"row\" class=\"row-header\">Dependency</th>\n\n\n <td class=\"content-container\">\n \n <em>Description</em>: Library QICoreCommon\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: https://madie.cms.gov/Library/QICoreCommon|4.0.000\n <br/>\n <em>Canonical URL</em>: <tt>https://madie.cms.gov/Library/QICoreCommon|4.0.000</tt>\n \n </td>\n</tr>\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n \n\n\n \n \n\n\n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"data-requirements\"> </a>Data Requirements</th>\n\n\n</tr>\n \n \n \n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Patient\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-patient\n <br/> \n \n \n \n <em>Must Support Elements</em>: extension, url\n <br/>\n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Encounter\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter\n <br/> \n \n \n \n <em>Must Support Elements</em>: type, period, status, status.value, location, location.type, hospitalization, hospitalization.dischargeDisposition, diagnosis, diagnosis.code\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: type</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.279\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Encounter\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter\n <br/> \n \n \n \n <em>Must Support Elements</em>: type, period, status, status.value, location, location.type, hospitalization, hospitalization.dischargeDisposition, diagnosis, diagnosis.code\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: type</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1010\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Encounter\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter\n <br/> \n \n \n \n <em>Must Support Elements</em>: period, location, location.type, hospitalization, hospitalization.dischargeDisposition, type, diagnosis, diagnosis.code\n <br/>\n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Encounter\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter\n <br/> \n \n \n \n <em>Must Support Elements</em>: type, status, status.value, period, location, location.type, hospitalization, hospitalization.dischargeDisposition, diagnosis, diagnosis.code\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: type</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Encounter\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter\n <br/> \n \n \n \n <em>Must Support Elements</em>: type, period, status, status.value, location, location.type, hospitalization, hospitalization.dischargeDisposition, diagnosis, diagnosis.code\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: type</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Resource\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/StructureDefinition/Resource\n <br/> \n \n \n \n <em>Must Support Elements</em>: id, id.value\n <br/>\n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Location\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-location\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: ServiceRequest\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-servicerequest\n <br/> \n \n \n \n <em>Must Support Elements</em>: code, status, status.value, authoredOn, authoredOn.value, intent, intent.value\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: code</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.294\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: ServiceRequest\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-servicerequest\n <br/> \n \n \n \n <em>Must Support Elements</em>: code, status, status.value, authoredOn, authoredOn.value\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: code</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: ServiceRequest\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-servicerequest\n <br/> \n \n \n \n <em>Must Support Elements</em>: code, status, status.value, authoredOn, authoredOn.value\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: code</span>\n <br/>\n \n \n \n \n <span class=\"tab-one\"><em>Code(s)</em>: \n \n \n http://snomed.info/sct#5751000175101: 'Patient bed assigned (finding)'\n \n \n </span>\n <br/>\n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Observation\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-observation-clinical-result\n <br/> \n \n \n \n <em>Must Support Elements</em>: code\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: code</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.163\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Observation\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-simple-observation\n <br/> \n \n \n \n <em>Must Support Elements</em>: code, value\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: code</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.163\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Claim\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-claim\n <br/> \n \n \n \n <em>Must Support Elements</em>: status, status.value, use, use.value, item\n <br/>\n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Condition\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-encounter-diagnosis\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Condition\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-problems-health-concerns\n <br/> \n \n \n \n \n </td>\n</tr>\n\n<tr>\n <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n <td class=\"content-container\">\n <em>Type</em>: Coverage\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-coverage\n <br/> \n \n \n \n <em>Must Support Elements</em>: type, period\n <br/>\n \n \n <em>Code Filter(s)</em>: \n <br/>\n \n \n <span class=\"tab-one\"><em>Path</em>: type</span>\n <br/>\n \n \n \n <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591\n <br/> \n \n \n \n \n </td>\n</tr>\n\n \n \n\n<tr>\n <th colspan=\"2\" scope=\"row\" class=\"row-header\">Generated using version 0.4.8 of the sample-content-ig Liquid templates</th>\n</tr>\n\n </tbody>\n </table>\n</div>"
},
"contained" : [
{
"resourceType" : "Library",
"id" : "effective-data-requirements",
"extension" : [
{
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
"valueCoding" : {
"system" : "http://snomed.info/sct",
"code" : "248153007",
"display" : "Male (finding)"
}
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
"valueCoding" : {
"system" : "http://snomed.info/sct",
"code" : "248152002",
"display" : "Female (finding)"
}
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
"valueCoding" : {
"system" : "http://terminology.hl7.org/CodeSystem/v3-RoleCode",
"code" : "ER",
"display" : "Emergency room"
}
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
"valueCoding" : {
"system" : "http://terminology.hl7.org/CodeSystem/v3-RoleCode",
"code" : "ETU",
"display" : "Emergency trauma unit"
}
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
"valueCoding" : {
"system" : "http://snomed.info/sct",
"code" : "21541000119102",
"display" : "Patient left without being seen (finding)"
}
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
"valueCoding" : {
"system" : "http://snomed.info/sct",
"code" : "5751000175101",
"display" : "Patient bed assigned (finding)"
}
},
{
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
"valueCoding" : {
"system" : "http://terminology.hl7.org/CodeSystem/ex-diagnosistype",
"code" : "principal",
"display" : "Principal Diagnosis"
}
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "SupplementalDataElements"
},
{
"url" : "name",
"valueString" : "SDE Sex"
},
{
"url" : "statement",
"valueString" : "define \"SDE Sex\":\n case\n when Patient.sex = '248153007' then \"Male (finding)\"\n when Patient.sex = '248152002' then \"Female (finding)\"\n else null\n end"
},
{
"url" : "displaySequence",
"valueInteger" : 0
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "SDE Sex"
},
{
"url" : "statement",
"valueString" : "define \"SDE Sex\":\n SDE.\"SDE Sex\""
},
{
"url" : "displaySequence",
"valueInteger" : 1
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Evaluation and Management"
},
{
"url" : "statement",
"valueString" : "define \"ED Evaluation and Management\":\n [Encounter: \"Emergency Department Evaluation and Management Visit\"] EDEvalManagementVisit\n where EDEvalManagementVisit.period ends during day of \"Measurement Period\"\n and EDEvalManagementVisit.status = 'finished'"
},
{
"url" : "displaySequence",
"valueInteger" : 2
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Triage"
},
{
"url" : "statement",
"valueString" : "define \"ED Triage\":\n ( [Encounter: \"Triage\"] EDTriage\n where EDTriage.period ends during day of \"Measurement Period\"\n and EDTriage.status in { 'finished', 'triaged' }\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 3
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Triage Excluding Those Prior To ED Encounters"
},
{
"url" : "statement",
"valueString" : "define \"ED Triage Excluding Those Prior To ED Encounters\":\n \"ED Triage\" EDTriageinMP\n where not exists ( \"ED Evaluation and Management\" EDEvalManagementInMP\n where ( ( EDTriageinMP.period overlaps before EDEvalManagementInMP.period )\n or ( EDTriageinMP.period during EDEvalManagementInMP.period )\n or ( EDEvalManagementInMP.period during EDTriageinMP.period )\n or ( EDTriageinMP.period ends 120 minutes or less before start of EDEvalManagementInMP.period )\n )\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 4
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Initial Population"
},
{
"url" : "statement",
"valueString" : "define \"Initial Population\":\n \"ED Evaluation and Management\"\n union \"ED Triage Excluding Those Prior To ED Encounters\""
},
{
"url" : "displaySequence",
"valueInteger" : 5
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Denominator"
},
{
"url" : "statement",
"valueString" : "define \"Denominator\":\n \"Initial Population\""
},
{
"url" : "displaySequence",
"valueInteger" : 6
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Triage Before Evaluation Management"
},
{
"url" : "statement",
"valueString" : "define \"ED Triage Before Evaluation Management\":\n \"ED Triage\" EDTriageinMP\n with \"Denominator\" EDEncounter\n such that ( ( EDTriageinMP.period overlaps before EDEncounter.period )\n or ( EDTriageinMP.period during EDEncounter.period )\n or ( EDEncounter.period during EDTriageinMP.period )\n or ( EDTriageinMP.period ends 120 minutes or less before start of EDEncounter.period )\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 7
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Triage and Evaluation Management"
},
{
"url" : "statement",
"valueString" : "define \"ED Triage and Evaluation Management\":\n \"Denominator\"\n union \"ED Triage Before Evaluation Management\""
},
{
"url" : "displaySequence",
"valueInteger" : 8
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Time to Treatment Room Greater Than 60 Minutes"
},
{
"url" : "statement",
"valueString" : "define \"Time to Treatment Room Greater Than 60 Minutes\":\n \"ED Evaluation and Management\" EDEvalManagementInMP\n where EDEvalManagementInMP.edArrivalTime ( ) 61 minutes or more before EDEvalManagementInMP.edTreatmentRoomTimeArrivalTime ( )"
},
{
"url" : "displaySequence",
"valueInteger" : 9
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Arrival Left Without Being Seen"
},
{
"url" : "statement",
"valueString" : "define \"ED Arrival Left Without Being Seen\":\n \"Denominator\" EDEncounter\n where EDEncounter.hospitalization.dischargeDisposition ~ \"Patient left without being seen (finding)\""
},
{
"url" : "displaySequence",
"valueInteger" : 10
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CQMCommon"
},
{
"url" : "name",
"valueString" : "Inpatient Encounter"
},
{
"url" : "statement",
"valueString" : "define \"Inpatient Encounter\":\n [Encounter: \"Encounter Inpatient\"] EncounterInpatient\n where EncounterInpatient.status = 'finished'\n and EncounterInpatient.period ends during day of \"Measurement Period\""
},
{
"url" : "displaySequence",
"valueInteger" : 11
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED To Inpatient Order"
},
{
"url" : "statement",
"valueString" : "define \"ED To Inpatient Order\":\n [ServiceRequest: \"Decision to Admit to Hospital Inpatient\"] AdmitIPOrder\n where AdmitIPOrder.status in { 'active', 'completed' }"
},
{
"url" : "displaySequence",
"valueInteger" : 12
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Decision to Admit Encounter Order"
},
{
"url" : "statement",
"valueString" : "define \"Decision to Admit Encounter Order\":\n \"Denominator\" EDEncounter\n with CQMCommon.\"Inpatient Encounter\" EncounterInpatient\n such that EncounterInpatient.admitDecisionUsingEncounterOrder ( ) 241 minutes or more before EDEncounter.edDepartureTime ( )"
},
{
"url" : "displaySequence",
"valueInteger" : 13
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Assessment In ED"
},
{
"url" : "statement",
"valueString" : "define \"Assessment In ED\":\n [\"ObservationClinicalResult\": \"Emergency Department Evaluation\"]\n union [\"SimpleObservation\": \"Emergency Department Evaluation\"] ObsInED\n where ObsInED.value as Concept in \"Admit Inpatient\""
},
{
"url" : "displaySequence",
"valueInteger" : 14
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Decision to Admit Using Assessment"
},
{
"url" : "statement",
"valueString" : "define \"Decision to Admit Using Assessment\":\n \"Denominator\" EDEncounter\n with CQMCommon.\"Inpatient Encounter\" EncounterInpatient\n such that EncounterInpatient.admitDecisionUsingAssessment ( ) 241 minutes or more before EDEncounter.edDepartureTime ( )"
},
{
"url" : "displaySequence",
"valueInteger" : 15
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Inpatient Or Bed Assignment Encounter Order"
},
{
"url" : "statement",
"valueString" : "define \"Inpatient Or Bed Assignment Encounter Order\":\n ( [ServiceRequest: \"Encounter Inpatient\"]\n union [ServiceRequest: \"Patient bed assigned (finding)\"] ) IPRequest\n where IPRequest.status in { 'active', 'completed' }"
},
{
"url" : "displaySequence",
"valueInteger" : 16
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Time of Admit Order Or Bed Assignment to Departure Greater Than 241 Minutes"
},
{
"url" : "statement",
"valueString" : "define \"Time of Admit Order Or Bed Assignment to Departure Greater Than 241 Minutes\":\n \"Denominator\" EDEncounter\n with CQMCommon.\"Inpatient Encounter\" InpatientEncounter\n such that InpatientEncounter.admitInpatientOrBedAssignmentEncounterOrder ( ) 241 minutes or more before EDEncounter.edDepartureTime ( )"
},
{
"url" : "displaySequence",
"valueInteger" : 17
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Admitted to Inpatient 241 Minutes or More Before Departure"
},
{
"url" : "statement",
"valueString" : "define \"Admitted to Inpatient 241 Minutes or More Before Departure\":\n \"Denominator\" EDEncounter\n with CQMCommon.\"Inpatient Encounter\" Inpatient\n such that Inpatient.holdingInEDAfterAdmission ( ) 241 minutes or more before EDEncounter.edDepartureTime ( )"
},
{
"url" : "displaySequence",
"valueInteger" : 18
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Boarded Time Greater Than 240 Minutes"
},
{
"url" : "statement",
"valueString" : "define \"Boarded Time Greater Than 240 Minutes\":\n \"Decision to Admit Encounter Order\"\n union \"Decision to Admit Using Assessment\"\n union \"Time of Admit Order Or Bed Assignment to Departure Greater Than 241 Minutes\"\n union \"Admitted to Inpatient 241 Minutes or More Before Departure\""
},
{
"url" : "displaySequence",
"valueInteger" : 19
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Observation Status"
},
{
"url" : "statement",
"valueString" : "define \"ED Observation Status\":\n [Encounter: \"Observation Services\"] EDObsEncounter\n with \"Denominator\" EDEncounter\n such that EDObsEncounter.period during EDEncounter.period\n and EDObsEncounter.status = 'finished'"
},
{
"url" : "displaySequence",
"valueInteger" : 20
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Boarded Time Greater Than 240 Minutes and No Observation Stay"
},
{
"url" : "statement",
"valueString" : "define \"Boarded Time Greater Than 240 Minutes and No Observation Stay\":\n ( \"Boarded Time Greater Than 240 Minutes\" Boarding\n where not exists ( \"ED Observation Status\" EDObs\n where ( EDObs.period during Boarding.period )\n )\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 21
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Length of Stay Greater Than 480 Minutes"
},
{
"url" : "statement",
"valueString" : "define \"ED Length of Stay Greater Than 480 Minutes\":\n \"Denominator\" EDEncounter\n where EDEncounter.edArrivalTime ( ) 481 minutes or more before EDEncounter.edDepartureTime ( )"
},
{
"url" : "displaySequence",
"valueInteger" : 22
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Length of Stay Greater Than 480 Minutes and No Observation Stay"
},
{
"url" : "statement",
"valueString" : "define \"ED Length of Stay Greater Than 480 Minutes and No Observation Stay\":\n ( \"ED Length of Stay Greater Than 480 Minutes\" EDStay\n where not exists ( \"ED Observation Status\" EDObs\n where ( EDObs.period during EDStay.period )\n )\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 23
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Numerator"
},
{
"url" : "statement",
"valueString" : "define \"Numerator\":\n \"Time to Treatment Room Greater Than 60 Minutes\"\n union \"ED Arrival Left Without Being Seen\"\n union \"Boarded Time Greater Than 240 Minutes and No Observation Stay\"\n union \"ED Length of Stay Greater Than 480 Minutes and No Observation Stay\""
},
{
"url" : "displaySequence",
"valueInteger" : 24
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Encounter or Triage of Patients 18 Years and Older"
},
{
"url" : "statement",
"valueString" : "define \"ED Encounter or Triage of Patients 18 Years and Older\":\n \"Denominator\" EDEncounter\n where AgeInYearsAt(date from start of \"Measurement Period\") >= 18"
},
{
"url" : "displaySequence",
"valueInteger" : 25
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Adult With Mental Health Diagnosis"
},
{
"url" : "statement",
"valueString" : "define \"Adult With Mental Health Diagnosis\":\n ( \"ED Encounter or Triage of Patients 18 Years and Older\" AdultEDEncounters\n where ( AdultEDEncounters.hasPrincipalDiagnosisOf ( \"Mental Health Diagnosis without Substance Use Disorders\" ) )\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 26
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Stratification 4"
},
{
"url" : "statement",
"valueString" : "define \"Stratification 4\":\n \"Adult With Mental Health Diagnosis\""
},
{
"url" : "displaySequence",
"valueInteger" : 27
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "ED Encounter or Triage of Patients Less Than 18 Years"
},
{
"url" : "statement",
"valueString" : "define \"ED Encounter or Triage of Patients Less Than 18 Years\":\n \"Denominator\" EDEncounter\n where AgeInYearsAt(date from start of \"Measurement Period\") < 18"
},
{
"url" : "displaySequence",
"valueInteger" : 28
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Pediatric With Mental Health Diagnosis"
},
{
"url" : "statement",
"valueString" : "define \"Pediatric With Mental Health Diagnosis\":\n ( \"ED Encounter or Triage of Patients Less Than 18 Years\" PediatricEDEncounters\n where ( PediatricEDEncounters.hasPrincipalDiagnosisOf ( \"Mental Health Diagnosis without Substance Use Disorders\" ) )\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 29
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Stratification 3"
},
{
"url" : "statement",
"valueString" : "define \"Stratification 3\":\n \"Pediatric With Mental Health Diagnosis\""
},
{
"url" : "displaySequence",
"valueInteger" : 30
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Adult With No Mental Health Diagnosis"
},
{
"url" : "statement",
"valueString" : "define \"Adult With No Mental Health Diagnosis\":\n ( \"ED Encounter or Triage of Patients 18 Years and Older\" AdultEDEncounters\n where not ( AdultEDEncounters.hasPrincipalDiagnosisOf ( \"Mental Health Diagnosis without Substance Use Disorders\" ) )\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 31
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Stratification 2"
},
{
"url" : "statement",
"valueString" : "define \"Stratification 2\":\n \"Adult With No Mental Health Diagnosis\""
},
{
"url" : "displaySequence",
"valueInteger" : 32
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Pediatric With No Mental Health Diagnosis"
},
{
"url" : "statement",
"valueString" : "define \"Pediatric With No Mental Health Diagnosis\":\n ( \"ED Encounter or Triage of Patients Less Than 18 Years\" PediatricEDEncounters\n where not ( PediatricEDEncounters.hasPrincipalDiagnosisOf ( \"Mental Health Diagnosis without Substance Use Disorders\" ) )\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 33
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "Stratification 1"
},
{
"url" : "statement",
"valueString" : "define \"Stratification 1\":\n \"Pediatric With No Mental Health Diagnosis\""
},
{
"url" : "displaySequence",
"valueInteger" : 34
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "SupplementalDataElements"
},
{
"url" : "name",
"valueString" : "SDE Payer"
},
{
"url" : "statement",
"valueString" : "define \"SDE Payer\":\n [Coverage: type in \"Payer Type\"] Payer\n return {\n code: Payer.type,\n period: Payer.period\n }"
},
{
"url" : "displaySequence",
"valueInteger" : 35
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "SDE Payer"
},
{
"url" : "statement",
"valueString" : "define \"SDE Payer\":\n SDE.\"SDE Payer\""
},
{
"url" : "displaySequence",
"valueInteger" : 36
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "SupplementalDataElements"
},
{
"url" : "name",
"valueString" : "SDE Ethnicity"
},
{
"url" : "statement",
"valueString" : "define \"SDE Ethnicity\":\n Patient.ethnicity E\n return Tuple {\n codes: { E.ombCategory } union E.detailed,\n display: E.text\n }"
},
{
"url" : "displaySequence",
"valueInteger" : 37
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "SDE Ethnicity"
},
{
"url" : "statement",
"valueString" : "define \"SDE Ethnicity\":\n SDE.\"SDE Ethnicity\""
},
{
"url" : "displaySequence",
"valueInteger" : 38
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "SupplementalDataElements"
},
{
"url" : "name",
"valueString" : "SDE Race"
},
{
"url" : "statement",
"valueString" : "define \"SDE Race\":\n Patient.race R\n return Tuple {\n codes: R.ombCategory union R.detailed,\n display: R.text\n }"
},
{
"url" : "displaySequence",
"valueInteger" : 39
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "SDE Race"
},
{
"url" : "statement",
"valueString" : "define \"SDE Race\":\n SDE.\"SDE Race\""
},
{
"url" : "displaySequence",
"valueInteger" : 40
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "FHIRHelpers"
},
{
"url" : "name",
"valueString" : "ToString"
},
{
"url" : "statement",
"valueString" : "define function ToString(value uri): value.value"
},
{
"url" : "displaySequence",
"valueInteger" : 41
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "FHIRHelpers"
},
{
"url" : "name",
"valueString" : "ToInterval"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Converts the given [Period](https://hl7.org/fhir/datatypes.html#Period)\nvalue to a CQL DateTime Interval\n@comment: If the start value of the given period is unspecified, the starting\nboundary of the resulting interval will be open (meaning the start of the interval\nis unknown, as opposed to interpreted as the beginning of time).\n*/\ndefine function ToInterval(period FHIR.Period):\n if period is null then\n null\n else\n if period.\"start\" is null then\n Interval(period.\"start\".value, period.\"end\".value]\n else\n Interval[period.\"start\".value, period.\"end\".value]"
},
{
"url" : "displaySequence",
"valueInteger" : 42
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "edArrivalTime"
},
{
"url" : "statement",
"valueString" : "define fluent function \"edArrivalTime\"(EDEncounter Encounter):\n Last(\"ED Triage and Evaluation Management\".location Location\n where exists((Location.location.getLocation().type) LocationType\n where(LocationType in \"Emergency Department Location\"\n or LocationType ~ \"Emergency room\"\n or LocationType ~ \"Emergency trauma unit\"\n )\n )\n and start of Location.period is not null\n and(Location.period ends 120 minutes or less before start of EDEncounter.period\n or Location.period overlaps before EDEncounter.period\n or EDEncounter.period overlaps before Location.period\n or Location.period starts same as start of EDEncounter.period\n )\n return start of Location.period\n sort ascending\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 43
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CQMCommon"
},
{
"url" : "name",
"valueString" : "getLocation"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Returns the Location resource specified by the given reference.\n*/\ndefine fluent function getLocation(reference Reference):\n singleton from (\n [Location] L where reference.references(L)\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 44
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "QICoreCommon"
},
{
"url" : "name",
"valueString" : "references"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Returns true if the given reference is to the given resource\n@comment: Returns true if the `id` element of the given resource exactly equals the tail of the given reference.\nNOTE: This function assumes resources from the same source server.\n*/\ndefine fluent function references(reference Reference, resource Resource):\n resource.id = Last(Split(reference.reference, '/'))"
},
{
"url" : "displaySequence",
"valueInteger" : 45
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "FHIRHelpers"
},
{
"url" : "name",
"valueString" : "ToConcept"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Converts the given FHIR [CodeableConcept](https://hl7.org/fhir/datatypes.html#CodeableConcept) value to a CQL Concept.\n*/\ndefine function ToConcept(concept FHIR.CodeableConcept):\n if concept is null then\n null\n else\n System.Concept {\n codes: concept.coding C return ToCode(C),\n display: concept.text.value\n }"
},
{
"url" : "displaySequence",
"valueInteger" : 46
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "FHIRHelpers"
},
{
"url" : "name",
"valueString" : "ToCode"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Converts the given FHIR [Coding](https://hl7.org/fhir/datatypes.html#Coding) value to a CQL Code.\n*/\ndefine function ToCode(coding FHIR.Coding):\n if coding is null then\n null\n else\n System.Code {\n code: coding.code.value,\n system: coding.system.value,\n version: coding.version.value,\n display: coding.display.value\n }"
},
{
"url" : "displaySequence",
"valueInteger" : 47
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "edTreatmentRoomTimeArrivalTime"
},
{
"url" : "statement",
"valueString" : "define fluent function \"edTreatmentRoomTimeArrivalTime\"(EDEncounter Encounter):\n First(EDEncounter.location Location\n where Location.location.getLocation().type in \"Emergency Department Treatment Location\"\n and start of Location.period is not null\n return start of Location.period\n sort ascending\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 48
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "admitDecisionUsingEncounterOrder"
},
{
"url" : "statement",
"valueString" : "define fluent function \"admitDecisionUsingEncounterOrder\"(EncounterInpatient Encounter):\n Last(\"ED To Inpatient Order\" AdmitOrder\n let LastEDVisit: EncounterInpatient.lastEDEncounter()\n where AdmitOrder.authoredOn during LastEDVisit.period\n and AdmitOrder.intent ~ 'order'\n return AdmitOrder.authoredOn\n sort ascending\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 49
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "lastEDEncounter"
},
{
"url" : "statement",
"valueString" : "define fluent function \"lastEDEncounter\"(EncounterInpatient Encounter):\n Last(\"ED Evaluation and Management\" EDEvalManagementInMP\n where EDEvalManagementInMP.period starts 1 day or less before or on start of EncounterInpatient.period\n and EDEvalManagementInMP.period starts before start of EncounterInpatient.period\n and EDEvalManagementInMP.period during day of \"Measurement Period\"\n and EDEvalManagementInMP.status = 'finished'\n sort by \n end of period ascending\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 50
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "edDepartureTime"
},
{
"url" : "statement",
"valueString" : "define fluent function \"edDepartureTime\"(EDEncounter Encounter):\n Last(\"ED Triage and Evaluation Management\".location Location\n where exists((Location.location.getLocation().type) LocationType\n where(LocationType in \"Emergency Department Location\"\n or LocationType ~ \"Emergency room\"\n or LocationType ~ \"Emergency trauma unit\"\n )\n )\n and \n end of Location.period is not null\n and(Location.period ends 120 minutes or less before start of EDEncounter.period\n or Location.period overlaps before EDEncounter.period\n or EDEncounter.period overlaps before Location.period\n or Location.period starts same as start of EDEncounter.period\n )\n return \n end of Location.period\n sort ascending\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 51
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "admitDecisionUsingAssessment"
},
{
"url" : "statement",
"valueString" : "define fluent function \"admitDecisionUsingAssessment\"(EncounterInpatient Encounter):\n Last(\"Assessment In ED\" EDEvaluation\n let LastEDVisit: EncounterInpatient.lastEDEncounter()\n where EDEvaluation.effective.toInterval() starts during LastEDVisit.period\n and EDEvaluation.status in { 'final', 'amended', 'corrected' }\n return start of EDEvaluation.effective.toInterval()\n sort ascending\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 52
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "admitInpatientOrBedAssignmentEncounterOrder"
},
{
"url" : "statement",
"valueString" : "define fluent function \"admitInpatientOrBedAssignmentEncounterOrder\"(Encounter Encounter):\n Last((\"Inpatient Or Bed Assignment Encounter Order\") AdmitInpatientOrder\n let LastEDVisit: Encounter.lastEDEncounter()\n where AdmitInpatientOrder.authoredOn during LastEDVisit.period\n return AdmitInpatientOrder.authoredOn\n sort ascending\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 53
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS1244FHIRECATHOQR"
},
{
"url" : "name",
"valueString" : "holdingInEDAfterAdmission"
},
{
"url" : "statement",
"valueString" : "define fluent function holdingInEDAfterAdmission(InpatientEncounter Encounter):\n Last(CQMCommon.\"Inpatient Encounter\" AdmittedInpatient\n let LastEDVisit: InpatientEncounter.lastEDEncounter()\n where start of AdmittedInpatient.period during LastEDVisit.period\n return start of AdmittedInpatient.period\n sort ascending\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 54
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CQMCommon"
},
{
"url" : "name",
"valueString" : "hasPrincipalDiagnosisOf"
},
{
"url" : "statement",
"valueString" : "/*\n @description: Returns the condition that is specified as the principal diagnosis for the encounter and has a code in the given valueSet.\n @comment: See the QICore 6 Authoring Patterns discussion on [Principal Diagnosis and Present on Admission](https://github.com/cqframework/CQL-Formatting-and-Usage-Wiki/wiki/Authoring-Patterns-QICore-v6.0.0#conditions-present-on-admission-and-principal-diagnoses) for more information\n */\n define fluent function hasPrincipalDiagnosisOf(encounter Encounter, valueSet ValueSet):\n (encounter.principalDiagnosis()) PD\n return PD.diagnosis in valueSet\n or PD.diagnosis.getCondition().code in valueSet"
},
{
"url" : "displaySequence",
"valueInteger" : 55
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CQMCommon"
},
{
"url" : "name",
"valueString" : "principalDiagnosis"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Returns the claim diagnosis element that is specified as the principal diagnosis for the encounter\n @comment: See the QICore 6 Authoring Patterns discussion on [Principal Diagnosis and Present on Admission](https://github.com/cqframework/CQL-Formatting-and-Usage-Wiki/wiki/Authoring-Patterns-QICore-v6.0.0#conditions-present-on-admission-and-principal-diagnoses) for more information\n*/\ndefine fluent function principalDiagnosis(encounter Encounter):\nsingleton from (\n (encounter.claimDiagnosis()) CD\n where CD.type.includesCode(\"Principal Diagnosis\")\n )"
},
{
"url" : "displaySequence",
"valueInteger" : 56
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CQMCommon"
},
{
"url" : "name",
"valueString" : "claimDiagnosis"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Returns the claim diagnosis elements for the given encounter\n@comment: See the QICore 6 Authoring Patterns discussion on [Principal Diagnosis and Present on Admission](https://github.com/cqframework/CQL-Formatting-and-Usage-Wiki/wiki/Authoring-Patterns-QICore-v6.0.0#conditions-present-on-admission-and-principal-diagnoses) for more information\n*/\ndefine fluent function claimDiagnosis(encounter Encounter):\n encounter E\n let \n claim: ([Claim] C where C.status = 'active' and C.use = 'claim' and exists (C.item I where I.encounter.references(E))),\n claimItem: (claim.item I where I.encounter.references(E))\n return claim.diagnosis D where D.sequence in claimItem.diagnosisSequence"
},
{
"url" : "displaySequence",
"valueInteger" : 57
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "QICoreCommon"
},
{
"url" : "name",
"valueString" : "references"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Returns true if any of the given references are to the given resource\n@comment: Returns true if the `id` element of the given resource exactly equals the tail of any of the given references.\nNOTE: This function assumes resources from the same source server.\n*/\ndefine fluent function references(references List<Reference>, resource Resource):\n exists (references R where R.references(resource))"
},
{
"url" : "displaySequence",
"valueInteger" : 58
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "QICoreCommon"
},
{
"url" : "name",
"valueString" : "includesCode"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Returns true if the given code is in the given codeList\n@comment: Returns true if the `code` is equivalent to any of the codes in the given `codeList`, false otherwise.\n*/\ndefine fluent function includesCode(codeList List<Concept>, code Code):\n exists (codeList C where C ~ code)"
},
{
"url" : "displaySequence",
"valueInteger" : 59
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CQMCommon"
},
{
"url" : "name",
"valueString" : "getCondition"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Returns the Condition resource for the given reference\n*/\ndefine fluent function getCondition(reference Reference):\n singleton from (([ConditionEncounterDiagnosis] union [ConditionProblemsHealthConcerns]) C where reference.references(C.id))"
},
{
"url" : "displaySequence",
"valueInteger" : 60
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "QICoreCommon"
},
{
"url" : "name",
"valueString" : "references"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Returns true if the given reference is to the given resourceId\n@comment: Returns true if the `resourceId` parameter exactly equals the tail of the given reference.\nNOTE: This function assumes resources from the same source server.\n*/\ndefine fluent function references(reference Reference, resourceId String):\n resourceId = Last(Split(reference.reference, '/'))"
},
{
"url" : "displaySequence",
"valueInteger" : 61
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
}
],
"name" : "EffectiveDataRequirements",
"status" : "active",
"type" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/library-type",
"code" : "module-definition"
}
]
},
"relatedArtifact" : [
{
"type" : "depends-on",
"display" : "QICore model information",
"resource" : "http://hl7.org/fhir/Library/QICore-ModelInfo"
},
{
"type" : "depends-on",
"display" : "Library SDE",
"resource" : "https://madie.cms.gov/Library/SupplementalDataElements|5.1.000"
},
{
"type" : "depends-on",
"display" : "Library FHIRHelpers",
"resource" : "https://madie.cms.gov/Library/FHIRHelpers|4.4.000"
},
{
"type" : "depends-on",
"display" : "Library CQMCommon",
"resource" : "https://madie.cms.gov/Library/CQMCommon|4.1.000"
},
{
"type" : "depends-on",
"display" : "Library QICoreCommon",
"resource" : "https://madie.cms.gov/Library/QICoreCommon|4.0.000"
},
{
"type" : "depends-on",
"display" : "Code system SNOMEDCT",
"resource" : "http://snomed.info/sct"
},
{
"type" : "depends-on",
"display" : "Code system RoleCode",
"resource" : "http://terminology.hl7.org/CodeSystem/v3-RoleCode"
},
{
"type" : "depends-on",
"display" : "Code system Diagnosis Type",
"resource" : "http://terminology.hl7.org/CodeSystem/ex-diagnosistype"
},
{
"type" : "depends-on",
"display" : "Value set Emergency Department Evaluation and Management Visit",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1010"
},
{
"type" : "depends-on",
"display" : "Value set Triage",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.279"
},
{
"type" : "depends-on",
"display" : "Value set Emergency Department Location",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.284"
},
{
"type" : "depends-on",
"display" : "Value set Emergency Department Treatment Location",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.278"
},
{
"type" : "depends-on",
"display" : "Value set Encounter Inpatient",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307"
},
{
"type" : "depends-on",
"display" : "Value set Decision to Admit to Hospital Inpatient",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.294"
},
{
"type" : "depends-on",
"display" : "Value set Emergency Department Evaluation",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.163"
},
{
"type" : "depends-on",
"display" : "Value set Admit Inpatient",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.164"
},
{
"type" : "depends-on",
"display" : "Value set Observation Services",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143"
},
{
"type" : "depends-on",
"display" : "Value set Mental Health Diagnosis without Substance Use Disorders",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.285"
},
{
"type" : "depends-on",
"display" : "Value set Payer Type",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591"
}
],
"parameter" : [
{
"name" : "Measurement Period",
"use" : "in",
"min" : 0,
"max" : "1",
"type" : "Period"
},
{
"name" : "Numerator",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Denominator",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Initial Population",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "SDE Sex",
"use" : "out",
"min" : 0,
"max" : "1",
"type" : "Coding"
},
{
"name" : "SDE Payer",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "SDE Ethnicity",
"use" : "out",
"min" : 0,
"max" : "1",
"type" : "Resource"
},
{
"name" : "SDE Race",
"use" : "out",
"min" : 0,
"max" : "1",
"type" : "Resource"
},
{
"name" : "Stratification 4",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Stratification 3",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Stratification 2",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Stratification 1",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
}
],
"dataRequirement" : [
{
"type" : "Patient",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-patient"
],
"mustSupport" : [
"extension",
"url"
]
},
{
"type" : "Encounter",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
],
"mustSupport" : [
"type",
"period",
"status",
"status.value",
"location",
"location.type",
"hospitalization",
"hospitalization.dischargeDisposition",
"diagnosis",
"diagnosis.code"
],
"codeFilter" : [
{
"path" : "type",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.279"
}
]
},
{
"type" : "Encounter",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
],
"mustSupport" : [
"type",
"period",
"status",
"status.value",
"location",
"location.type",
"hospitalization",
"hospitalization.dischargeDisposition",
"diagnosis",
"diagnosis.code"
],
"codeFilter" : [
{
"path" : "type",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1010"
}
]
},
{
"type" : "Encounter",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
],
"mustSupport" : [
"period",
"location",
"location.type",
"hospitalization",
"hospitalization.dischargeDisposition",
"type",
"diagnosis",
"diagnosis.code"
]
},
{
"type" : "Encounter",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
],
"mustSupport" : [
"type",
"status",
"status.value",
"period",
"location",
"location.type",
"hospitalization",
"hospitalization.dischargeDisposition",
"diagnosis",
"diagnosis.code"
],
"codeFilter" : [
{
"path" : "type",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307"
}
]
},
{
"type" : "Encounter",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
],
"mustSupport" : [
"type",
"period",
"status",
"status.value",
"location",
"location.type",
"hospitalization",
"hospitalization.dischargeDisposition",
"diagnosis",
"diagnosis.code"
],
"codeFilter" : [
{
"path" : "type",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143"
}
]
},
{
"type" : "Resource",
"profile" : [
🔗 "http://hl7.org/fhir/StructureDefinition/Resource"
],
"mustSupport" : [
"id",
"id.value"
]
},
{
"type" : "Location",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-location"
]
},
{
"type" : "ServiceRequest",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-servicerequest"
],
"mustSupport" : [
"code",
"status",
"status.value",
"authoredOn",
"authoredOn.value",
"intent",
"intent.value"
],
"codeFilter" : [
{
"path" : "code",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.294"
}
]
},
{
"type" : "ServiceRequest",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-servicerequest"
],
"mustSupport" : [
"code",
"status",
"status.value",
"authoredOn",
"authoredOn.value"
],
"codeFilter" : [
{
"path" : "code",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307"
}
]
},
{
"type" : "ServiceRequest",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-servicerequest"
],
"mustSupport" : [
"code",
"status",
"status.value",
"authoredOn",
"authoredOn.value"
],
"codeFilter" : [
{
"path" : "code",
"code" : [
{
"system" : "http://snomed.info/sct",
"code" : "5751000175101",
"display" : "Patient bed assigned (finding)"
}
]
}
]
},
{
"type" : "Observation",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-observation-clinical-result"
],
"mustSupport" : [
"code"
],
"codeFilter" : [
{
"path" : "code",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.163"
}
]
},
{
"type" : "Observation",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-simple-observation"
],
"mustSupport" : [
"code",
"value"
],
"codeFilter" : [
{
"path" : "code",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.163"
}
]
},
{
"type" : "Claim",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-claim"
],
"mustSupport" : [
"status",
"status.value",
"use",
"use.value",
"item"
]
},
{
"type" : "Condition",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-encounter-diagnosis"
]
},
{
"type" : "Condition",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-problems-health-concerns"
]
},
{
"type" : "Coverage",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-coverage"
],
"mustSupport" : [
"type",
"period"
],
"codeFilter" : [
{
"path" : "type",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.114222.4.11.3591"
}
]
}
]
}
],
"extension" : [
{
"id" : "supplementalDataGuidance",
"extension" : [
{
"url" : "guidance",
"valueString" : "For every patient evaluated by this measure also identify payer, race, ethnicity and sex"
},
{
"url" : "usage",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
"code" : "supplemental-data",
"display" : "Supplemental Data"
}
],
"text" : "Supplemental Data Guidance"
}
}
],
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-supplementalDataGuidance"
},
{
"extension" : [
{
"url" : "term",
"valueString" : "Boarding"
},
{
"url" : "definition",
"valueMarkdown" : "The practice of holding inpatients in the emergency department after admission to the hospital because no hospital inpatient bed is available. (American College of Emergency Physicians \\[ACEP\\], 2018).\n"
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
},
{
"extension" : [
{
"url" : "term",
"valueString" : "ED Observation"
},
{
"url" : "definition",
"valueMarkdown" : "Observation stays are inclusive of both ED observation care in which a patient initially evaluated in the ED is cared for under observation status for an extended period of time in the ED or in a care area dedicated to observation care, as well as hospital observation stays in which a patient initially evaluated in the ED is cared for in observation status often in a hospital bed used for both inpatient or observation status admissions. Because these two forms of observation stays cannot be easily distinguished in a standardized fashion in existing electronic health record data ontologies, for the purposes of this quality measure all observation stays have been considered an exclusion from both numerator criteria 3 and 4.\n"
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
},
{
"extension" : [
{
"url" : "term",
"valueString" : "Left Without Being Seen (LWBS)"
},
{
"url" : "definition",
"valueMarkdown" : "Patients arrive to the ED for evaluation and leave before seeing a physician, advanced practice nurse, or physician's assistant.\n"
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
},
{
"extension" : [
{
"url" : "term",
"valueString" : "Mental Health"
},
{
"url" : "definition",
"valueMarkdown" : "Mental health generally refers to mental health diagnoses, life stressors and crises, and stress-related physical symptoms (American Medical Association \\[AMA\\], 2022). For this measure, mental health conditions will be defined separately from substance use disorders.\n"
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
},
{
"url" : "http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-effectiveDataRequirements",
"valueReference" : {
"reference" : "#effective-data-requirements"
}
}
],
"url" : "https://madie.cms.gov/Measure/CMS1244FHIRECATHOQR",
"identifier" : [
{
"use" : "usual",
"type" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/artifact-identifier-type",
"code" : "short-name",
"display" : "Short Name"
}
]
},
"system" : "https://madie.cms.gov/measure/shortName",
"value" : "CMS1244FHIR"
},
{
"use" : "official",
"type" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/artifact-identifier-type",
"code" : "version-independent",
"display" : "Version Independent"
}
]
},
"system" : "urn:ietf:rfc:3986",
"value" : "urn:uuid:1d711504-ebec-41de-81b0-d1993115eac2"
},
{
"use" : "official",
"type" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/artifact-identifier-type",
"code" : "version-specific",
"display" : "Version Specific"
}
]
},
"system" : "urn:ietf:rfc:3986",
"value" : "urn:uuid:43ee6832-7bc9-4247-a51c-6d8052f1a222"
},
{
"use" : "official",
"type" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/artifact-identifier-type",
"code" : "endorser",
"display" : "Endorser"
}
]
},
"system" : "https://madie.cms.gov/measure/cbeId",
"value" : "4625e",
"assigner" : {
"display" : "CMS Consensus Based Entity"
}
},
{
"use" : "official",
"type" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/artifact-identifier-type",
"code" : "publisher",
"display" : "Publisher"
}
]
},
"system" : "https://madie.cms.gov/measure/cmsId",
"value" : "1244FHIR",
"assigner" : {
"display" : "CMS"
}
}
],
"version" : "1.0.000",
"name" : "CMS1244FHIRECATHOQR",
"title" : "Emergency Care Access \\& Timeliness (HOQR)FHIR\n",
"status" : "active",
"experimental" : false,
"date" : "2025-08-25T19:54:05+00:00",
"publisher" : "Centers for Medicare & Medicaid Services (CMS)",
"contact" : [
{
"telecom" : [
{
"system" : "url",
"value" : "https://www.cms.gov/"
}
]
}
],
"description" : "This measure assesses the variation in access and timeliness of emergency care to support hospital quality improvement for patients requiring emergency care in an emergency department (ED). This measure is designed to align with incentives to promote improved care both in EDs and the broader health system to help identify where patients do not receive timely access to emergency care. Emergency care access and timeliness gaps are inclusive of several concepts pertaining to boarding and crowding in an ED, including significantly longer ED wait times, higher left without being seen rates, longer boarding times, and longer total length of stay in the ED.\n",
"usage" : "Measure Score Calculation The measure score is first calculated at the individual ED level as the proportion of ED visits where any one of the four outcomes occurred, as defined by the numerator. Scores will be standardized z-scores by ED case volume strata (defined in ED visit volume bands of 20,000 visits). For CMS Certification Numbers (CCNs) with more than one ED, volume-adjusted z-scores are then combined as a weighted average for that CCN. A z-score of greater than zero means worse performance and less than zero means better performance, compared to like EDs. For the purposes of this measure, a decision to admit can be captured using any of the following: - an evaluation that results in a decision to admit - an order to admit to inpatient - an order for a bed assignment - start of inpatient admission This dQM is an episode-based measure. An episode is defined as an ED visit that ends during the measurement period. This FHIR-based measure has been derived from the QDM-based measure: CMS1244v1. Please refer to the HL7 QI-Core Implementation Guide (*++https://hl7.org/fhir/us/qicore/STU6/++* ) for more information on QI-Core and mapping recommendations from QDM to QI-Core STU 6 (*++https://hl7.org/fhir/us/qicore/STU6/qdm-to-qicore.html++*).\n",
"copyright" : "Limited proprietary coding is contained in these specifications for user convenience. Users of proprietary code sets should obtain all necessary licenses from the owners of the code sets. This material contains SNOMED Clinical Terms(R) (SNOMED CT\\[R\\]) copyright 2004-2024 International Health Terminology Standards Development Organisation. All rights reserved. ICD-10 copyright 2024 World Health Organization. All Rights Reserved. CPT(R) contained in the Measure specifications is copyright 2004-2024 American Medical Association.\n",
"effectivePeriod" : {
"start" : "2027-01-01",
"end" : "2027-12-31"
},
"author" : [
{
"name" : "Acumen, LLC",
"telecom" : [
{
"system" : "url",
"value" : "https://www.acumenllc.com/"
}
]
}
],
"relatedArtifact" : [
{
"type" : "citation",
"citation" : "American College of Emergency Physicians. (2018). Definition of Boarded Patient. Policy Statements. https://www.acep.org/patient-care/policy-statements/definition-of-boarded-patient\n"
},
{
"type" : "citation",
"citation" : "American Medical Association. (2022). What is Behavioral Health. https://www.ama-assn.org/delivering-care/public-health/what-behavioral-health\n"
},
{
"type" : "citation",
"citation" : "Centers for Disease Control and Prevention. (2021). Emergency Department Visits. https://www.cdc.gov/nchs/fastats/emergency-department.htm\n"
},
{
"type" : "citation",
"citation" : "eCQI Resource Center. (n.d). Median Admit Decision Time to ED Departure Time for Admitted Patients.\n"
}
],
"library" : [
🔗 "https://madie.cms.gov/Library/CMS1244FHIRECATHOQR"
],
"disclaimer" : "These performance specifications are not clinical guidelines, do not establish a standard of medical care, and have not been tested for all potential applications. THE MEASURES AND SPECIFICATIONS ARE PROVIDED \"AS IS\" WITHOUT WARRANTY OF ANY KIND. Due to technical limitations, registered trademarks are indicated by (R) or \\[R\\] and unregistered trademarks are indicated by (TM) or \\[TM\\].\n",
"rationale" : "This measure aims to reduce patient harm and improve outcomes for patients requiring emergency care in an ED by addressing the variation in emergency care and measuring access and timeliness of emergency care. There are long-standing concerns about parameters that impact access and timeliness of care in the ED. Currently, there are no national metrics to assess the proportion of patients impacted by access and timeliness of ED care.\n",
"clinicalRecommendationStatement" : "The goal of the Emergency Care Access \\& Timeliness (ECAT) measure is to assess and improve the safety of the 140 million ED visits that patients experience each year (Centers for Disease Control and Prevention \\[CDC\\], 2021). Limitations in access and timeliness of emergency care have been shown to be associated with harm, such as increases in mortality, delays in care, preventable errors, poor patient experience, and staff burnout. These quality limitations are also associated with increased costs of care. The ECAT measure under consideration is intended for use in CMS's Hospital Outpatient Quality Reporting (HOQR) program. The numerator is comprised of all ED visits with a quality gap in access as defined in the numerator criteria. Challenges related to emergency care access and timeliness have been increasing and have prompted public calls for action. This measure improves upon previous efforts as it measures the mean instead of the median to highlight the presence of extreme quality gaps, and captures several indicators of quality gaps by using multiple numerator criteria. Implementation of this measure, which captures multiple components of access and timeliness, can help identify facilities where patients do not receive timely access to emergency care as defined in the numerator criteria. This measure, therefore, could positively impact millions of patients who seek treatment in the ED and help address long-standing disparities in emergency care, including for patients with mental health diagnoses.\n",
"group" : [
{
"id" : "Group_1",
"extension" : [
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-scoring",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-scoring",
"code" : "proportion",
"display" : "Proportion"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-populationBasis",
"valueCode" : "Encounter"
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-type",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-type",
"code" : "outcome",
"display" : "Outcome"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-rateAggregation",
"valueString" : "None\n"
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-improvementNotation",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-improvement-notation",
"code" : "decrease",
"display" : "Decreased score indicates improvement"
}
]
}
}
],
"population" : [
{
"id" : "InitialPopulation_1",
"code" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "initial-population",
"display" : "Initial Population"
}
]
},
"description" : "All ED visits that end during the measurement period for all patients\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Initial Population"
}
},
{
"id" : "Denominator_1",
"code" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "denominator",
"display" : "Denominator"
}
]
},
"description" : "Equals Initial Population\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Denominator"
}
},
{
"id" : "Numerator_1",
"code" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "numerator",
"display" : "Numerator"
}
]
},
"description" : "The numerator is comprised of ED visits meeting the denominator criteria and where the patient experiences any of the following quality gaps in access: 1. The patient waited longer than 60 minutes (1 hour) after arrival to the ED to be placed in a treatment room or dedicated treatment area that allows for audiovisual privacy during history-taking and physical examination, or 2. The patient left the ED without being evaluated, or 3. The patient boarded (time from Decision to Admit order to ED departure for admitted patients) in the ED for longer than 240 minutes (4 hours), or 4. The patient had an ED length of stay (LOS) (time from ED arrival to ED departure as defined by the ED departure timestamp indicating when the patient physically left the ED) of longer than 480 minutes (8 hours). ED encounters with ED observation stays are excluded from criteria #3 (boarding) and #4 (ED LOS). To clarify, patients who have a 'decision to admit' after an ED observation stay remain excluded from criteria #3 (boarded) calculations.\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Numerator"
}
}
],
"stratifier" : [
{
"id" : "Stratification_1_1",
"extension" : [
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "initial-population",
"display" : "Initial Population"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "denominator",
"display" : "Denominator"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "numerator",
"display" : "Numerator"
}
]
}
}
],
"description" : "All patients aged less than 18 years seen in the ED who do not have an ED encounter principal diagnosis consistent with mental health diagnosis. Patients who have an ED encounter principal diagnosis consistent with substance use disorders will be included in this stratification.\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Stratification 1"
}
},
{
"id" : "Stratification_1_2",
"extension" : [
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "initial-population",
"display" : "Initial Population"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "denominator",
"display" : "Denominator"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "numerator",
"display" : "Numerator"
}
]
}
}
],
"description" : "All patients aged 18 years and older seen in the ED who do not have an ED encounter principal diagnosis consistent with mental health diagnosis. Patients who have an ED encounter principal diagnosis consistent with substance use disorders will be included in this stratification.\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Stratification 2"
}
},
{
"id" : "Stratification_1_3",
"extension" : [
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "initial-population",
"display" : "Initial Population"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "denominator",
"display" : "Denominator"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "numerator",
"display" : "Numerator"
}
]
}
}
],
"description" : "All patients aged less than 18 years seen in the ED who have an ED encounter principal diagnosis consistent with mental health diagnosis.\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Stratification 3"
}
},
{
"id" : "Stratification_1_4",
"extension" : [
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "initial-population",
"display" : "Initial Population"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "denominator",
"display" : "Denominator"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-appliesTo",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "numerator",
"display" : "Numerator"
}
]
}
}
],
"description" : "All patients aged 18 years and older seen in the ED who have an ED encounter principal diagnosis consistent with mental health diagnosis.\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Stratification 4"
}
}
]
}
],
"supplementalData" : [
{
"id" : "sde-ethnicity",
"usage" : [
{
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
"code" : "supplemental-data"
}
]
}
],
"description" : "SDE Ethnicity\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "SDE Ethnicity"
}
},
{
"id" : "sde-payer",
"usage" : [
{
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
"code" : "supplemental-data"
}
]
}
],
"description" : "SDE Payer\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "SDE Payer"
}
},
{
"id" : "sde-race",
"usage" : [
{
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
"code" : "supplemental-data"
}
]
}
],
"description" : "SDE Race\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "SDE Race"
}
},
{
"id" : "sde-sex",
"usage" : [
{
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
"code" : "supplemental-data"
}
]
}
],
"description" : "SDE Sex\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "SDE Sex"
}
}
]
}