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-22 |
{
"resourceType" : "Measure",
"id" : "CMS157FHIRPainIntensityQuantified",
"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\">Oncology: Medical and Radiation Pain Intensity QuantifiedFHIR</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\">CMS157FHIR</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:b7b487bf-bc27-48c9-994f-6d095ff84500</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:0f0317d4-38c3-4b87-b0a9-9b74aaa9a466</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\">157FHIR</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\">0384e</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\">2026-01-01 through 2026-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\">American Society of Clinical Oncology</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\">American Society of Clinical Oncology</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\"><p>Percentage of patient visits, regardless of patient age, with a diagnosis of cancer currently receiving chemotherapy or radiation therapy in which pain intensity is quantified</p></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\"><p>Copyright 2025 American Society of Clinical Oncology. All Rights Reserved.</p></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\"><p>The Measure is not a clinical guideline, does not establish a standard of medical care, and has not been tested for all potential applications.</p>\n<p>The Measure, while copyrighted, can be reproduced and distributed, without modification, for noncommercial purposes, e.g., use by health care providers in connection with their practices. Commercial use is defined as the sale, license, or distribution of the Measure for commercial gain, or incorporation of the Measure into a product or service that is sold, licensed or distributed for commercial gain.</p>\n<p>Commercial uses of the Measure require a license agreement between the user and American Society of Clinical Oncology (ASCO) and prior written approval of ASCO. Contact measurement@asco.org for licensing this measure. Neither ASCO nor its members shall be responsible for any use of the Measure.</p>\n<p>The PCPI’s and American Medical Association’s significant past efforts and contributions to the development and updating of the Measures are acknowledged.</p>\n<p>ASCO is solely responsible for the review and enhancement ("Maintenance") of the Measure as of June 2020.</p>\n<p>ASCO encourages the use of the Measure by other health care professionals, where appropriate.</p>\n<p>THE MEASURE AND SPECIFICATIONS ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND.</p>\n<p>Limited proprietary coding may be contained in the Measure specifications for convenience. A license agreement must be entered prior to a third party’s use of Current Procedural Terminology (CPT[R]) or other proprietary code set contained in the Measures. Any other use of CPT or other coding by the third party is strictly prohibited. ASCO and its members disclaim all liability for use or accuracy of any CPT or other coding contained in the specifications.</p>\n<p>CPT(R) contained in the Measure specifications is copyright 2004-2024 American Medical Association. LOINC(R) is copyright 2004-2024 Regenstrief Institute, Inc. This material contains SNOMED Clinical Terms(R) (SNOMED CT[R]) copyright 2004-2024 International Health Terminology Standards Development Organisation. ICD-10 is copyright 2024 World Health Organization. All Rights Reserved.</p>\n<p>Due to technical limitations, registered trademarks are indicated by (R) or [R].</p></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\"><p>Pain is a commonly occurring symptom for cancer patients as 30% to 50% (510,000 to 850,000 each year based on current statistics) will experience moderate to severe pain (Wiffen, Wee, Derry, Bell, & Moore, 2017). Initial and ongoing pain assessments are essential to determine the pathophysiology of pain and ensure proper pain management. According to the National Comprehensive Cancer Network (NCCN, 2024), undertreatment of pain remains a problem among a significant subset of cancer patients, survival is linked with symptom control and pain management, and pain management contributes to broad quality of life improvement. Furthermore, NCCN notes that formal pain reevaluation is required at each contact to ensure that pain management therapies are successfully meeting patient-specific goals for comfort, function, and safety. Cancer patients have reported that pain interferes with their mood, work, relationships with other people, sleep and overall enjoyment of life (Moryl et al., 2018). Pain management is an essential part of oncologic management and contributes to a patient’s overall function and quality of life (NCCN, 2024).</p>\n<p>A recent analysis of registry data for chronic pain cancer patients found average pain intensity reported as mild (24.6% of patients), moderate (41.5%), and severe (33.9%). The study also indicated that patient report of pain relief is inversely related to the average pain intensity reported (Moryl et al., 2018). These data suggest that assessing and managing a cancer patient’s pain is critical and there remains significant room for improvement in assessing and mitigating cancer-related pain. A prospective study of changes in pain severity of cancer patients found that, at initial assessment, 47% of patients reported pain. At follow-up, the patients with pain at initial assessment reported reduced pain (32.2%), stable pain (48.2%) and worse pain (19.6%). Of the 53% of patients reporting no pain at initial assessment, 82.6% reported stable pain and 17.4% reported worse pain at follow-up assessment (Zhao et al., 2014). This study highlights the importance of initial and ongoing assessments of pain to identify gaps and ensure proper pain management.</p></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\"><ul>\n <li><p>Screen all patients for pain at each contact.</p></li>\n <li><p>Routinely quantify and document pain intensity and quality as characterized by the patient (whenever possible). Include patient reporting of breakthrough pain, treatments used and their impact on pain, satisfaction with pain relief, pain interference, provider assessment of impact on function, and any special issues for the patient relevant to pain treatment and access to care. If necessary, get additional information from caregiver regarding pain and impact on function.</p></li>\n <li><p>Perform comprehensive pain assessment if new or worsening pain is present and regularly for persisting pain.</p><p>Various methods and tools exist to assess pain severity. Intensity of pain should be quantified using a numerical rating scale (i.e., 0-10), visual analog scale, categorical scale, or pictorial scale (e.g., The Faces Pain Rating Scale) (Category 2A) (National Comprehensive Cancer Network, 2024).</p></li>\n</ul></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 Moryl, N., Dave, V., Glare, P., Bokhari, A., Malhotra, V. T., Gulati, A., … Inturrisi, C. E. (2018). Patient-Reported Outcomes and Opioid Use by Outpatient Cancer Patients. The Journal of Pain: official journal of the American Pain Society, 19(3), 278–290. doi:10.1016/j.jpain.2017.11.001\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 National Comprehensive Cancer Network (NCCN). (2024). NCCN Clinical Practice Guidelines in Oncology. Adult Cancer Pain Version 2.2024. Retrieved from http://www.nccn.org\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 Wiffen, P. J., Wee, B., Derry, S., Bell, R. F., & Moore, R. A. (2017). Opioids for cancer pain - an overview of Cochrane reviews. The Cochrane database of systematic reviews, 7(7), CD012592. doi:10.1002/14651858.CD012592.pub2\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 Zhao, F., Chang, V. T., Cleeland, C., Cleary, J. F., Mitchell, E. P., Wagner, L. I., & Fisch, M. J. (2014). Determinants of pain severity changes in ambulatory patients with cancer: an analysis from Eastern Cooperative Oncology Group trial E2Z02. Journal of clinical oncology: official journal of the American Society of Clinical Oncology, 32(4), 312–319. doi:10.1200/JCO.2013.50.6071\n \n \n \n \n \n </td>\n</tr>\n\n\n\n\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>This eCQM is an episode-based measure. An episode is defined as each eligible encounter for patients with a diagnosis of cancer who are also currently receiving chemotherapy or radiation therapy during the measurement period.</p>\n<p>For patients receiving radiation therapy, pain intensity should be quantified at each radiation treatment management encounter where the patient and physician have a face-to-face interaction. Due to the nature of some applicable coding related to radiation therapy (e.g., delivered in multiple fractions), the billing date for certain codes may or may not be the same as the face-to-face encounter date. In this instance, for the reporting purposes of this measure, the billing date should be used to pull the appropriate patients into the initial population. It is expected, though, that the numerator criteria would be performed at the time of the actual face-to-face encounter during the series of treatments. A lookback (retrospective) period of 7 days, including the billing date, may be used to identify the actual face-to-face encounter, which is required to assess the numerator. Therefore, pain intensity should be quantified during the face-to-face encounter occurring on the actual billing date or within the 6 days prior to the billing date.</p>\n<p>For patients receiving chemotherapy, pain intensity should be quantified at each face-to-face or telehealth encounter with the physician while the patient is currently receiving chemotherapy. For purposes of identifying eligible encounters, patients "currently receiving chemotherapy" refers to patients administered chemotherapy on the same day as the encounter or during the 30 days before the date of the encounter AND during the 30 days after the date of the encounter.</p>\n<p>Pain intensity should be quantified using a standard instrument, such as a 0-10 numerical rating scale, visual analog scale, a categorical scale, or pictorial scale. Examples include the Faces Pain Rating Scale and the Brief Pain Inventory (BPI).</p>\n<p>This FHIR-based measure has been derived from the QDM-based measure: CMS157v14. 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 STU6 (https://hl7.org/fhir/us/qicore/STU6/qdm-to-qicore.html).</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<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Summary</th>\n\n\n<td class=\"content-container\"><p>Percentage of patient visits, regardless of patient age, with a diagnosis of cancer currently receiving chemotherapy in which pain intensity is quantified</p></td>\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#process: 'Process']</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\"><p>This measure is intended to have one reporting rate, which aggregates the following populations into a single performance rate for reporting purposes:</p>\n<ul>\n <li><p>Population 1: Visits for patients with a diagnosis of cancer who are currently receiving chemotherapy</p></li>\n <li><p>Population 2: Visits for patients with a diagnosis of cancer who are currently receiving radiation therapy</p></li>\n</ul>\n<p>For the purposes of this measure, a single performance rate can be calculated as follows:</p>\n<p>Performance Rate = (Numerator 1 + Numerator 2)/ (Denominator 1 + Denominator 2)</p></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#increase: 'Increased 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\"><p>All patient visits, regardless of patient age, with a diagnosis of cancer currently receiving chemotherapy</p></p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms157fhirpainintensityquantified-initial-population-1\">Initial Population 1</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\"><p>Equals Initial Population</p></p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms157fhirpainintensityquantified-denominator-1\">Denominator 1</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\"><p>Patient visits in which pain intensity is quantified</p></p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms157fhirpainintensityquantified-numerator-1\">Numerator 1</a> \n \n \n </td>\n </tr>\n \n\n \n\n \n \n <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Measure Group (Rate) (ID: Group_2)</th>\n\n\n</tr>\n \n \n \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Summary</th>\n\n\n<td class=\"content-container\"><p>Percentage of patient visits, regardless of patient age, with a diagnosis of cancer currently receiving radiation therapy in which pain intensity is quantified</p></td>\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#process: 'Process']</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\"><p>This measure is intended to have one reporting rate, which aggregates the following populations into a single performance rate for reporting purposes:</p>\n<ul>\n <li><p>Population 1: Visits for patients with a diagnosis of cancer who are currently receiving chemotherapy</p></li>\n <li><p>Population 2: Visits for patients with a diagnosis of cancer who are currently receiving radiation therapy</p></li>\n</ul>\n<p>For the purposes of this measure, a single performance rate can be calculated as follows:</p>\n<p>Performance Rate = (Numerator 1 + Numerator 2)/ (Denominator 1 + Denominator 2)</p></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#increase: 'Increased 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_2\n <br/>\n \n \n <em>Description</em>:\n <p style=\"white-space: pre-line\" class=\"tab-one\"><p>All patient visits, regardless of patient age, with a diagnosis of cancer currently receiving radiation therapy</p></p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms157fhirpainintensityquantified-initial-population-2\">Initial Population 2</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_2\n <br/>\n \n \n <em>Description</em>:\n <p style=\"white-space: pre-line\" class=\"tab-one\"><p>Equals Initial Population</p></p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms157fhirpainintensityquantified-denominator-2\">Denominator 2</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_2\n <br/>\n \n \n <em>Description</em>:\n <p style=\"white-space: pre-line\" class=\"tab-one\"><p>Patient visits in which pain intensity is quantified</p></p>\n \n \n \n \n <em>Logic Definition</em>: <a href=\"#primary-cms157fhirpainintensityquantified-numerator-2\">Numerator 2</a> \n \n \n </td>\n </tr>\n \n\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=\"#cms157fhirpainintensityquantified-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=\"#cms157fhirpainintensityquantified-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=\"#cms157fhirpainintensityquantified-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=\"#cms157fhirpainintensityquantified-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/CMS157FHIRPainIntensityQuantified</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 \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-cms157fhirpainintensityquantified-initial-population-1\"> </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 1":\n "Face to Face or Telehealth Encounter with Ongoing Chemotherapy"</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 <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms157fhirpainintensityquantified-denominator-1\"> </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 1":\n "Initial Population 1"</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 <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms157fhirpainintensityquantified-numerator-1\"> </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 1":\n "Face to Face or Telehealth Encounter with Ongoing Chemotherapy" FaceToFaceOrTelehealthEncounterWithChemo\n with "Standard Pain Assessment with Result" PainAssessed\n such that PainAssessed.effective.toInterval ( ) during day of FaceToFaceOrTelehealthEncounterWithChemo.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 <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Measure Group (Rate) (ID: Group_2)</th>\n\n\n</tr>\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-cms157fhirpainintensityquantified-initial-population-2\"> </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 2":\n "Radiation Treatment Management During Measurement Period with Cancer 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 <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms157fhirpainintensityquantified-denominator-2\"> </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 2":\n "Initial Population 2"</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 <tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"primary-cms157fhirpainintensityquantified-numerator-2\"> </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 2":\n "Radiation Treatment Management During Measurement Period with Cancer Diagnosis" RadiationManagementEncounter\n with "Standard Pain Assessment with Result" PainAssessed\n such that case\n when exists ( ( RadiationManagementEncounter.type ) RadiationManagement\n where RadiationManagement ~ "Radiation treatment management, 5 treatments"\n ) then PainAssessed.effective.toInterval ( ) 6 days or less on or before day of start of RadiationManagementEncounter.period \n else PainAssessed.effective.toInterval ( ) during day of RadiationManagementEncounter.period 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 <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<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\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<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms157fhirpainintensityquantified-sde-sex\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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=\"cms157fhirpainintensityquantified-radiation-treatment-management-during-measurement-period-with-cancer-diagnosis\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 "Radiation Treatment Management During Measurement Period with Cancer Diagnosis":\n ( [Encounter: "Radiation Treatment Management"] ) RadiationTreatmentManagement\n with ( [ConditionProblemsHealthConcerns: "Cancer"]\n union [ConditionEncounterDiagnosis: "Cancer"] ) CancerDx\n such that CancerDx.prevalenceInterval ( ) overlaps day of RadiationTreatmentManagement.period\n where RadiationTreatmentManagement.period during day of "Measurement Period"\n and RadiationTreatmentManagement.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=\"cms157fhirpainintensityquantified-initial-population-2\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 2":\n "Radiation Treatment Management During Measurement Period with Cancer 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=\"cms157fhirpainintensityquantified-denominator-2\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 2":\n "Initial Population 2"</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=\"cms157fhirpainintensityquantified-chemotherapy-within-31-days-prior-and-during-measurement-period\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 "Chemotherapy Within 31 Days Prior and During Measurement Period":\n [Procedure: "Chemotherapy Administration"] ChemoAdministration\n where ChemoAdministration.performed.toInterval ( ) during Interval[start of "Measurement Period" - 31 days, end of "Measurement Period"]\n and ChemoAdministration.status in { 'completed', 'in-progress' }</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=\"cms157fhirpainintensityquantified-face-to-face-or-telehealth-encounter-with-ongoing-chemotherapy\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 "Face to Face or Telehealth Encounter with Ongoing Chemotherapy":\n from\n ( [Encounter: "Office Visit"]\n union [Encounter: "Audio Visual Telehealth Encounter"] ) FaceToFaceOrTelehealthEncounter,\n "Chemotherapy Within 31 Days Prior and During Measurement Period" ChemoBeforeEncounter,\n "Chemotherapy Within 31 Days Prior and During Measurement Period" ChemoAfterEncounter,\n ( [ConditionProblemsHealthConcerns: "Cancer"]\n union [ConditionEncounterDiagnosis: "Cancer"] ) CancerDx\n where CancerDx.prevalenceInterval ( ) overlaps day of FaceToFaceOrTelehealthEncounter.period\n and ChemoBeforeEncounter.performed.toInterval ( ) starts 30 days or less on or before day of end of FaceToFaceOrTelehealthEncounter.period\n and ChemoAfterEncounter.performed.toInterval ( ) starts 30 days or less on or after day of end of FaceToFaceOrTelehealthEncounter.period\n and not ( ChemoAfterEncounter.performed.toInterval ( ) same day as ChemoBeforeEncounter.performed.toInterval ( ) )\n and FaceToFaceOrTelehealthEncounter.period during day of "Measurement Period"\n and FaceToFaceOrTelehealthEncounter.status = 'finished'\n return FaceToFaceOrTelehealthEncounter</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=\"cms157fhirpainintensityquantified-standard-pain-assessment-with-result\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 "Standard Pain Assessment with Result":\n [ObservationScreeningAssessment: "Standardized Pain Assessment Tool"] AssessedPain\n where AssessedPain.value is not null</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=\"cms157fhirpainintensityquantified-numerator-1\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 1":\n "Face to Face or Telehealth Encounter with Ongoing Chemotherapy" FaceToFaceOrTelehealthEncounterWithChemo\n with "Standard Pain Assessment with Result" PainAssessed\n such that PainAssessed.effective.toInterval ( ) during day of FaceToFaceOrTelehealthEncounterWithChemo.period</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=\"cms157fhirpainintensityquantified-sde-payer\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms157fhirpainintensityquantified-numerator-2\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 2":\n "Radiation Treatment Management During Measurement Period with Cancer Diagnosis" RadiationManagementEncounter\n with "Standard Pain Assessment with Result" PainAssessed\n such that case\n when exists ( ( RadiationManagementEncounter.type ) RadiationManagement\n where RadiationManagement ~ "Radiation treatment management, 5 treatments"\n ) then PainAssessed.effective.toInterval ( ) 6 days or less on or before day of start of RadiationManagementEncounter.period \n else PainAssessed.effective.toInterval ( ) during day of RadiationManagementEncounter.period end</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=\"cms157fhirpainintensityquantified-initial-population-1\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 1":\n "Face to Face or Telehealth Encounter with Ongoing Chemotherapy"</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=\"cms157fhirpainintensityquantified-sde-ethnicity\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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=\"cms157fhirpainintensityquantified-sde-race\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"cms157fhirpainintensityquantified-denominator-1\"> </a>\n \n Logic Definition\n </th>\n\n <td class=\"content-container\"><em>Library Name:</em> CMS157FHIRPainIntensityQuantified</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 1":\n "Initial Population 1"</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<tr>\n <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n \n \n <a name=\"qicorecommon-tointerval\"> </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: Normalizes a value that is a choice of timing-valued types to an equivalent interval\n@comment: Normalizes a choice type of DateTime, Quanitty, Interval<DateTime>, or Interval<Quantity> types\nto an equivalent interval. This selection of choice types is a superset of the majority of choice types that are used as possible\nrepresentations for timing-valued elements in QICore, allowing this function to be used across any resource.\nThe input can be provided as a DateTime, Quantity, Interval<DateTime> or Interval<Quantity>.\nThe intent of this function is to provide a clear and concise mechanism to treat single\nelements that have multiple possible representations as intervals so that logic doesn't have to account\nfor the variability. More complex calculations (such as medication request period or dispense period\ncalculation) need specific guidance and consideration. That guidance may make use of this function, but\nthe focus of this function is on single element calculations where the semantics are unambiguous.\nIf the input is a DateTime, the result a DateTime Interval beginning and ending on that DateTime.\nIf the input is a Quantity, the quantity is expected to be a calendar-duration interpreted as an Age,\nand the result is a DateTime Interval beginning on the Date the patient turned that age and ending immediately before one year later.\nIf the input is a DateTime Interval, the result is the input.\nIf the input is a Quantity Interval, the quantities are expected to be calendar-durations interpreted as an Age, and the result\nis a DateTime Interval beginning on the date the patient turned the age given as the start of the quantity interval, and ending\nimmediately before one year later than the date the patient turned the age given as the end of the quantity interval.\nIf the input is a Timing, an error will be thrown indicating that Timing calculations are not implemented. Any other input will reslt in a null DateTime Interval\n*/\ndefine fluent function toInterval(choice Choice<DateTime, Quantity, Interval<DateTime>, Interval<Quantity>, Timing>):\n case\n\t when choice is DateTime then\n \tInterval[choice as DateTime, choice as DateTime]\n\t\twhen choice is Interval<DateTime> then\n \t\tchoice as Interval<DateTime>\n\t\twhen choice is Quantity then\n\t\t Interval[Patient.birthDate + (choice as Quantity),\n\t\t\t Patient.birthDate + (choice as Quantity) + 1 year)\n\t\twhen choice is Interval<Quantity> then\n\t\t Interval[Patient.birthDate + (choice.low as Quantity),\n\t\t\t Patient.birthDate + (choice.high as Quantity) + 1 year)\n\t\twhen choice is Timing then\n Message(null, true, 'NOT_IMPLEMENTED', 'Error', 'Calculation of an interval from a Timing value is not supported') as Interval<DateTime>\n\t\telse\n\t\t\tnull as Interval<DateTime>\n\tend</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<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<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 <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<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 CPT\n \n <br/>\n \n \n \n \n \n \n <em>Resource</em>: http://www.ama-assn.org/go/cpt\n <br/>\n <em>Canonical URL</em>: <tt>http://www.ama-assn.org/go/cpt</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 Radiation Treatment Management\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.526.3.1026\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1026</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 Cancer\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.526.3.1010\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.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 Office 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.1001\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.1001</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 Audio Visual Telehealth Encounter\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.1444.5.215\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.1444.5.215</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 Chemotherapy Administration\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.526.3.1027\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1027</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 Standardized Pain Assessment Tool\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.526.3.1028\n <br/>\n <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1028</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>: Radiation treatment management, 5 treatments\n <br/>\n \n <em>Code</em>: 77427\n <br/>\n <em>System</em>: <tt>http://www.ama-assn.org/go/cpt</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 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 <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, birthDate, birthDate.value, 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\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.526.3.1026\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\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.1001\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\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.1444.5.215\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 <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.113883.3.526.3.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>: 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 <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.113883.3.526.3.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>: Procedure\n <br/>\n \n <em>Profile(s)</em>: \n \n http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-procedure\n <br/> \n \n \n \n <em>Must Support Elements</em>: code, performed, status, status.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.526.3.1027\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-observation-screening-assessment\n <br/> \n \n \n \n <em>Must Support Elements</em>: code, value, effective\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.526.3.1028\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://www.ama-assn.org/go/cpt",
"code" : "77427",
"display" : "Radiation treatment management, 5 treatments"
}
},
{
"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" : "CMS157FHIRPainIntensityQuantified"
},
{
"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" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Radiation Treatment Management During Measurement Period with Cancer Diagnosis"
},
{
"url" : "statement",
"valueString" : "define \"Radiation Treatment Management During Measurement Period with Cancer Diagnosis\":\n ( [Encounter: \"Radiation Treatment Management\"] ) RadiationTreatmentManagement\n with ( [ConditionProblemsHealthConcerns: \"Cancer\"]\n union [ConditionEncounterDiagnosis: \"Cancer\"] ) CancerDx\n such that CancerDx.prevalenceInterval ( ) overlaps day of RadiationTreatmentManagement.period\n where RadiationTreatmentManagement.period during day of \"Measurement Period\"\n and RadiationTreatmentManagement.status = 'finished'"
},
{
"url" : "displaySequence",
"valueInteger" : 2
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Initial Population 2"
},
{
"url" : "statement",
"valueString" : "define \"Initial Population 2\":\n \"Radiation Treatment Management During Measurement Period with Cancer Diagnosis\""
},
{
"url" : "displaySequence",
"valueInteger" : 3
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Denominator 2"
},
{
"url" : "statement",
"valueString" : "define \"Denominator 2\":\n \"Initial Population 2\""
},
{
"url" : "displaySequence",
"valueInteger" : 4
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Chemotherapy Within 31 Days Prior and During Measurement Period"
},
{
"url" : "statement",
"valueString" : "define \"Chemotherapy Within 31 Days Prior and During Measurement Period\":\n [Procedure: \"Chemotherapy Administration\"] ChemoAdministration\n where ChemoAdministration.performed.toInterval ( ) during Interval[start of \"Measurement Period\" - 31 days, end of \"Measurement Period\"]\n and ChemoAdministration.status in { 'completed', 'in-progress' }"
},
{
"url" : "displaySequence",
"valueInteger" : 5
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Face to Face or Telehealth Encounter with Ongoing Chemotherapy"
},
{
"url" : "statement",
"valueString" : "define \"Face to Face or Telehealth Encounter with Ongoing Chemotherapy\":\n from\n ( [Encounter: \"Office Visit\"]\n union [Encounter: \"Audio Visual Telehealth Encounter\"] ) FaceToFaceOrTelehealthEncounter,\n \"Chemotherapy Within 31 Days Prior and During Measurement Period\" ChemoBeforeEncounter,\n \"Chemotherapy Within 31 Days Prior and During Measurement Period\" ChemoAfterEncounter,\n ( [ConditionProblemsHealthConcerns: \"Cancer\"]\n union [ConditionEncounterDiagnosis: \"Cancer\"] ) CancerDx\n where CancerDx.prevalenceInterval ( ) overlaps day of FaceToFaceOrTelehealthEncounter.period\n and ChemoBeforeEncounter.performed.toInterval ( ) starts 30 days or less on or before day of end of FaceToFaceOrTelehealthEncounter.period\n and ChemoAfterEncounter.performed.toInterval ( ) starts 30 days or less on or after day of end of FaceToFaceOrTelehealthEncounter.period\n and not ( ChemoAfterEncounter.performed.toInterval ( ) same day as ChemoBeforeEncounter.performed.toInterval ( ) )\n and FaceToFaceOrTelehealthEncounter.period during day of \"Measurement Period\"\n and FaceToFaceOrTelehealthEncounter.status = 'finished'\n return FaceToFaceOrTelehealthEncounter"
},
{
"url" : "displaySequence",
"valueInteger" : 6
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Standard Pain Assessment with Result"
},
{
"url" : "statement",
"valueString" : "define \"Standard Pain Assessment with Result\":\n [ObservationScreeningAssessment: \"Standardized Pain Assessment Tool\"] AssessedPain\n where AssessedPain.value is not null"
},
{
"url" : "displaySequence",
"valueInteger" : 7
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Numerator 1"
},
{
"url" : "statement",
"valueString" : "define \"Numerator 1\":\n \"Face to Face or Telehealth Encounter with Ongoing Chemotherapy\" FaceToFaceOrTelehealthEncounterWithChemo\n with \"Standard Pain Assessment with Result\" PainAssessed\n such that PainAssessed.effective.toInterval ( ) during day of FaceToFaceOrTelehealthEncounterWithChemo.period"
},
{
"url" : "displaySequence",
"valueInteger" : 8
}
],
"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" : 9
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "SDE Payer"
},
{
"url" : "statement",
"valueString" : "define \"SDE Payer\":\n SDE.\"SDE Payer\""
},
{
"url" : "displaySequence",
"valueInteger" : 10
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Numerator 2"
},
{
"url" : "statement",
"valueString" : "define \"Numerator 2\":\n \"Radiation Treatment Management During Measurement Period with Cancer Diagnosis\" RadiationManagementEncounter\n with \"Standard Pain Assessment with Result\" PainAssessed\n such that case\n when exists ( ( RadiationManagementEncounter.type ) RadiationManagement\n where RadiationManagement ~ \"Radiation treatment management, 5 treatments\"\n ) then PainAssessed.effective.toInterval ( ) 6 days or less on or before day of start of RadiationManagementEncounter.period \n else PainAssessed.effective.toInterval ( ) during day of RadiationManagementEncounter.period end"
},
{
"url" : "displaySequence",
"valueInteger" : 11
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Initial Population 1"
},
{
"url" : "statement",
"valueString" : "define \"Initial Population 1\":\n \"Face to Face or Telehealth Encounter with Ongoing Chemotherapy\""
},
{
"url" : "displaySequence",
"valueInteger" : 12
}
],
"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" : 13
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "SDE Ethnicity"
},
{
"url" : "statement",
"valueString" : "define \"SDE Ethnicity\":\n SDE.\"SDE Ethnicity\""
},
{
"url" : "displaySequence",
"valueInteger" : 14
}
],
"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" : 15
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "SDE Race"
},
{
"url" : "statement",
"valueString" : "define \"SDE Race\":\n SDE.\"SDE Race\""
},
{
"url" : "displaySequence",
"valueInteger" : 16
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "CMS157FHIRPainIntensityQuantified"
},
{
"url" : "name",
"valueString" : "Denominator 1"
},
{
"url" : "statement",
"valueString" : "define \"Denominator 1\":\n \"Initial Population 1\""
},
{
"url" : "displaySequence",
"valueInteger" : 17
}
],
"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" : 18
}
],
"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" : 19
}
],
"url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
},
{
"extension" : [
{
"url" : "libraryName",
"valueString" : "QICoreCommon"
},
{
"url" : "name",
"valueString" : "toInterval"
},
{
"url" : "statement",
"valueString" : "/*\n@description: Normalizes a value that is a choice of timing-valued types to an equivalent interval\n@comment: Normalizes a choice type of DateTime, Quanitty, Interval<DateTime>, or Interval<Quantity> types\nto an equivalent interval. This selection of choice types is a superset of the majority of choice types that are used as possible\nrepresentations for timing-valued elements in QICore, allowing this function to be used across any resource.\nThe input can be provided as a DateTime, Quantity, Interval<DateTime> or Interval<Quantity>.\nThe intent of this function is to provide a clear and concise mechanism to treat single\nelements that have multiple possible representations as intervals so that logic doesn't have to account\nfor the variability. More complex calculations (such as medication request period or dispense period\ncalculation) need specific guidance and consideration. That guidance may make use of this function, but\nthe focus of this function is on single element calculations where the semantics are unambiguous.\nIf the input is a DateTime, the result a DateTime Interval beginning and ending on that DateTime.\nIf the input is a Quantity, the quantity is expected to be a calendar-duration interpreted as an Age,\nand the result is a DateTime Interval beginning on the Date the patient turned that age and ending immediately before one year later.\nIf the input is a DateTime Interval, the result is the input.\nIf the input is a Quantity Interval, the quantities are expected to be calendar-durations interpreted as an Age, and the result\nis a DateTime Interval beginning on the date the patient turned the age given as the start of the quantity interval, and ending\nimmediately before one year later than the date the patient turned the age given as the end of the quantity interval.\nIf the input is a Timing, an error will be thrown indicating that Timing calculations are not implemented. Any other input will reslt in a null DateTime Interval\n*/\ndefine fluent function toInterval(choice Choice<DateTime, Quantity, Interval<DateTime>, Interval<Quantity>, Timing>):\n case\n\t when choice is DateTime then\n \tInterval[choice as DateTime, choice as DateTime]\n\t\twhen choice is Interval<DateTime> then\n \t\tchoice as Interval<DateTime>\n\t\twhen choice is Quantity then\n\t\t Interval[Patient.birthDate + (choice as Quantity),\n\t\t\t Patient.birthDate + (choice as Quantity) + 1 year)\n\t\twhen choice is Interval<Quantity> then\n\t\t Interval[Patient.birthDate + (choice.low as Quantity),\n\t\t\t Patient.birthDate + (choice.high as Quantity) + 1 year)\n\t\twhen choice is Timing then\n Message(null, true, 'NOT_IMPLEMENTED', 'Error', 'Calculation of an interval from a Timing value is not supported') as Interval<DateTime>\n\t\telse\n\t\t\tnull as Interval<DateTime>\n\tend"
},
{
"url" : "displaySequence",
"valueInteger" : 20
}
],
"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" : 21
}
],
"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" : 22
}
],
"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 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 CPT",
"resource" : "http://www.ama-assn.org/go/cpt"
},
{
"type" : "depends-on",
"display" : "Value set Radiation Treatment Management",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1026"
},
{
"type" : "depends-on",
"display" : "Value set Cancer",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1010"
},
{
"type" : "depends-on",
"display" : "Value set Office Visit",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1001"
},
{
"type" : "depends-on",
"display" : "Value set Audio Visual Telehealth Encounter",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.1444.5.215"
},
{
"type" : "depends-on",
"display" : "Value set Chemotherapy Administration",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1027"
},
{
"type" : "depends-on",
"display" : "Value set Standardized Pain Assessment Tool",
"resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1028"
},
{
"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" : "Denominator 2",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Numerator 1",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Numerator 2",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Initial Population 1",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Initial Population 2",
"use" : "out",
"min" : 0,
"max" : "*",
"type" : "Resource"
},
{
"name" : "Denominator 1",
"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"
}
],
"dataRequirement" : [
{
"type" : "Patient",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-patient"
],
"mustSupport" : [
"extension",
"birthDate",
"birthDate.value",
"url"
]
},
{
"type" : "Encounter",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
],
"mustSupport" : [
"type",
"period",
"status",
"status.value"
],
"codeFilter" : [
{
"path" : "type",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1026"
}
]
},
{
"type" : "Encounter",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
],
"mustSupport" : [
"type",
"period",
"status",
"status.value"
],
"codeFilter" : [
{
"path" : "type",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1001"
}
]
},
{
"type" : "Encounter",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
],
"mustSupport" : [
"type",
"period",
"status",
"status.value"
],
"codeFilter" : [
{
"path" : "type",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.1444.5.215"
}
]
},
{
"type" : "Condition",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-problems-health-concerns"
],
"mustSupport" : [
"code"
],
"codeFilter" : [
{
"path" : "code",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1010"
}
]
},
{
"type" : "Condition",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-encounter-diagnosis"
],
"mustSupport" : [
"code"
],
"codeFilter" : [
{
"path" : "code",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1010"
}
]
},
{
"type" : "Procedure",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-procedure"
],
"mustSupport" : [
"code",
"performed",
"status",
"status.value"
],
"codeFilter" : [
{
"path" : "code",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1027"
}
]
},
{
"type" : "Observation",
"profile" : [
🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-observation-screening-assessment"
],
"mustSupport" : [
"code",
"value",
"effective"
],
"codeFilter" : [
{
"path" : "code",
"valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1028"
}
]
},
{
"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"
},
{
"url" : "http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-effectiveDataRequirements",
"valueReference" : {
"reference" : "#effective-data-requirements"
}
}
],
"url" : "https://madie.cms.gov/Measure/CMS157FHIRPainIntensityQuantified",
"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" : "CMS157FHIR"
},
{
"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:b7b487bf-bc27-48c9-994f-6d095ff84500"
},
{
"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:0f0317d4-38c3-4b87-b0a9-9b74aaa9a466"
},
{
"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" : "0384e",
"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" : "157FHIR",
"assigner" : {
"display" : "CMS"
}
}
],
"version" : "1.0.000",
"name" : "CMS157FHIRPainIntensityQuantified",
"title" : "Oncology: Medical and Radiation Pain Intensity QuantifiedFHIR\n",
"status" : "active",
"experimental" : false,
"date" : "2025-08-22T14:29:20+00:00",
"publisher" : "American Society of Clinical Oncology",
"contact" : [
{
"telecom" : [
{
"system" : "url",
"value" : "www.asco.org"
}
]
}
],
"description" : "Percentage of patient visits, regardless of patient age, with a diagnosis of cancer currently receiving chemotherapy or radiation therapy in which pain intensity is quantified\n",
"usage" : "This eCQM is an episode-based measure. An episode is defined as each eligible encounter for patients with a diagnosis of cancer who are also currently receiving chemotherapy or radiation therapy during the measurement period.\n\nFor patients receiving radiation therapy, pain intensity should be quantified at each radiation treatment management encounter where the patient and physician have a face-to-face interaction. Due to the nature of some applicable coding related to radiation therapy (e.g., delivered in multiple fractions), the billing date for certain codes may or may not be the same as the face-to-face encounter date. In this instance, for the reporting purposes of this measure, the billing date should be used to pull the appropriate patients into the initial population. It is expected, though, that the numerator criteria would be performed at the time of the actual face-to-face encounter during the series of treatments. A lookback (retrospective) period of 7 days, including the billing date, may be used to identify the actual face-to-face encounter, which is required to assess the numerator. Therefore, pain intensity should be quantified during the face-to-face encounter occurring on the actual billing date or within the 6 days prior to the billing date.\n\nFor patients receiving chemotherapy, pain intensity should be quantified at each face-to-face or telehealth encounter with the physician while the patient is currently receiving chemotherapy. For purposes of identifying eligible encounters, patients \"currently receiving chemotherapy\" refers to patients administered chemotherapy on the same day as the encounter or during the 30 days before the date of the encounter AND during the 30 days after the date of the encounter.\n\nPain intensity should be quantified using a standard instrument, such as a 0-10 numerical rating scale, visual analog scale, a categorical scale, or pictorial scale. Examples include the Faces Pain Rating Scale and the Brief Pain Inventory (BPI).\n\nThis FHIR-based measure has been derived from the QDM-based measure: CMS157v14. 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 STU6 (https://hl7.org/fhir/us/qicore/STU6/qdm-to-qicore.html).\n",
"copyright" : "Copyright 2025 American Society of Clinical Oncology. All Rights Reserved.\n",
"effectivePeriod" : {
"start" : "2026-01-01",
"end" : "2026-12-31"
},
"author" : [
{
"name" : "American Society of Clinical Oncology",
"telecom" : [
{
"system" : "url",
"value" : "www.asco.org"
}
]
}
],
"relatedArtifact" : [
{
"type" : "citation",
"citation" : "Moryl, N., Dave, V., Glare, P., Bokhari, A., Malhotra, V. T., Gulati, A., ... Inturrisi, C. E. (2018). Patient-Reported Outcomes and Opioid Use by Outpatient Cancer Patients. The Journal of Pain: official journal of the American Pain Society, 19(3), 278--290. doi:10.1016/j.jpain.2017.11.001\n"
},
{
"type" : "citation",
"citation" : "National Comprehensive Cancer Network (NCCN). (2024). NCCN Clinical Practice Guidelines in Oncology. Adult Cancer Pain Version 2.2024. Retrieved from http://www.nccn.org\n"
},
{
"type" : "citation",
"citation" : "Wiffen, P. J., Wee, B., Derry, S., Bell, R. F., \\& Moore, R. A. (2017). Opioids for cancer pain - an overview of Cochrane reviews. The Cochrane database of systematic reviews, 7(7), CD012592. doi:10.1002/14651858.CD012592.pub2\n"
},
{
"type" : "citation",
"citation" : "Zhao, F., Chang, V. T., Cleeland, C., Cleary, J. F., Mitchell, E. P., Wagner, L. I., \\& Fisch, M. J. (2014). Determinants of pain severity changes in ambulatory patients with cancer: an analysis from Eastern Cooperative Oncology Group trial E2Z02. Journal of clinical oncology: official journal of the American Society of Clinical Oncology, 32(4), 312--319. doi:10.1200/JCO.2013.50.6071\n"
}
],
"library" : [
🔗 "https://madie.cms.gov/Library/CMS157FHIRPainIntensityQuantified"
],
"disclaimer" : "The Measure is not a clinical guideline, does not establish a standard of medical care, and has not been tested for all potential applications.\n\nThe Measure, while copyrighted, can be reproduced and distributed, without modification, for noncommercial purposes, e.g., use by health care providers in connection with their practices. Commercial use is defined as the sale, license, or distribution of the Measure for commercial gain, or incorporation of the Measure into a product or service that is sold, licensed or distributed for commercial gain.\n\nCommercial uses of the Measure require a license agreement between the user and American Society of Clinical Oncology (ASCO) and prior written approval of ASCO. Contact measurement@asco.org for licensing this measure. Neither ASCO nor its members shall be responsible for any use of the Measure.\n\nThe PCPI's and American Medical Association's significant past efforts and contributions to the development and updating of the Measures are acknowledged.\n\nASCO is solely responsible for the review and enhancement (\"Maintenance\") of the Measure as of June 2020.\n\nASCO encourages the use of the Measure by other health care professionals, where appropriate.\n\nTHE MEASURE AND SPECIFICATIONS ARE PROVIDED \"AS IS\" WITHOUT WARRANTY OF ANY KIND.\n\nLimited proprietary coding may be contained in the Measure specifications for convenience. A license agreement must be entered prior to a third party's use of Current Procedural Terminology (CPT\\[R\\]) or other proprietary code set contained in the Measures. Any other use of CPT or other coding by the third party is strictly prohibited. ASCO and its members disclaim all liability for use or accuracy of any CPT or other coding contained in the specifications.\n\nCPT(R) contained in the Measure specifications is copyright 2004-2024 American Medical Association. LOINC(R) is copyright 2004-2024 Regenstrief Institute, Inc. This material contains SNOMED Clinical Terms(R) (SNOMED CT\\[R\\]) copyright 2004-2024 International Health Terminology Standards Development Organisation. ICD-10 is copyright 2024 World Health Organization. All Rights Reserved.\n\nDue to technical limitations, registered trademarks are indicated by (R) or \\[R\\].\n",
"rationale" : "Pain is a commonly occurring symptom for cancer patients as 30% to 50% (510,000 to 850,000 each year based on current statistics) will experience moderate to severe pain (Wiffen, Wee, Derry, Bell, \\& Moore, 2017). Initial and ongoing pain assessments are essential to determine the pathophysiology of pain and ensure proper pain management. According to the National Comprehensive Cancer Network (NCCN, 2024), undertreatment of pain remains a problem among a significant subset of cancer patients, survival is linked with symptom control and pain management, and pain management contributes to broad quality of life improvement. Furthermore, NCCN notes that formal pain reevaluation is required at each contact to ensure that pain management therapies are successfully meeting patient-specific goals for comfort, function, and safety. Cancer patients have reported that pain interferes with their mood, work, relationships with other people, sleep and overall enjoyment of life (Moryl et al., 2018). Pain management is an essential part of oncologic management and contributes to a patient's overall function and quality of life (NCCN, 2024).\n\nA recent analysis of registry data for chronic pain cancer patients found average pain intensity reported as mild (24.6% of patients), moderate (41.5%), and severe (33.9%). The study also indicated that patient report of pain relief is inversely related to the average pain intensity reported (Moryl et al., 2018). These data suggest that assessing and managing a cancer patient's pain is critical and there remains significant room for improvement in assessing and mitigating cancer-related pain. A prospective study of changes in pain severity of cancer patients found that, at initial assessment, 47% of patients reported pain. At follow-up, the patients with pain at initial assessment reported reduced pain (32.2%), stable pain (48.2%) and worse pain (19.6%). Of the 53% of patients reporting no pain at initial assessment, 82.6% reported stable pain and 17.4% reported worse pain at follow-up assessment (Zhao et al., 2014). This study highlights the importance of initial and ongoing assessments of pain to identify gaps and ensure proper pain management.\n",
"clinicalRecommendationStatement" : "* Screen all patients for pain at each contact.\n\n* Routinely quantify and document pain intensity and quality as characterized by the patient (whenever possible). Include patient reporting of breakthrough pain, treatments used and their impact on pain, satisfaction with pain relief, pain interference, provider assessment of impact on function, and any special issues for the patient relevant to pain treatment and access to care. If necessary, get additional information from caregiver regarding pain and impact on function.\n\n* Perform comprehensive pain assessment if new or worsening pain is present and regularly for persisting pain.\n\n Various methods and tools exist to assess pain severity. Intensity of pain should be quantified using a numerical rating scale (i.e., 0-10), visual analog scale, categorical scale, or pictorial scale (e.g., The Faces Pain Rating Scale) (Category 2A) (National Comprehensive Cancer Network, 2024).\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" : "process",
"display" : "Process"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-rateAggregation",
"valueString" : "This measure is intended to have one reporting rate, which aggregates the following populations into a single performance rate for reporting purposes:\n\n* Population 1: Visits for patients with a diagnosis of cancer who are currently receiving chemotherapy\n\n* Population 2: Visits for patients with a diagnosis of cancer who are currently receiving radiation therapy\n\nFor the purposes of this measure, a single performance rate can be calculated as follows:\n\nPerformance Rate = (Numerator 1 + Numerator 2)/ (Denominator 1 + Denominator 2)\n"
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-improvementNotation",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-improvement-notation",
"code" : "increase",
"display" : "Increased score indicates improvement"
}
]
}
}
],
"description" : "Percentage of patient visits, regardless of patient age, with a diagnosis of cancer currently receiving chemotherapy in which pain intensity is quantified\n",
"population" : [
{
"id" : "InitialPopulation_1",
"code" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "initial-population",
"display" : "Initial Population"
}
]
},
"description" : "All patient visits, regardless of patient age, with a diagnosis of cancer currently receiving chemotherapy\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Initial Population 1"
}
},
{
"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 1"
}
},
{
"id" : "Numerator_1",
"code" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "numerator",
"display" : "Numerator"
}
]
},
"description" : "Patient visits in which pain intensity is quantified\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Numerator 1"
}
}
]
},
{
"id" : "Group_2",
"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" : "process",
"display" : "Process"
}
]
}
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-rateAggregation",
"valueString" : "This measure is intended to have one reporting rate, which aggregates the following populations into a single performance rate for reporting purposes:\n\n* Population 1: Visits for patients with a diagnosis of cancer who are currently receiving chemotherapy\n\n* Population 2: Visits for patients with a diagnosis of cancer who are currently receiving radiation therapy\n\nFor the purposes of this measure, a single performance rate can be calculated as follows:\n\nPerformance Rate = (Numerator 1 + Numerator 2)/ (Denominator 1 + Denominator 2)\n"
},
{
"url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-improvementNotation",
"valueCodeableConcept" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-improvement-notation",
"code" : "increase",
"display" : "Increased score indicates improvement"
}
]
}
}
],
"description" : "Percentage of patient visits, regardless of patient age, with a diagnosis of cancer currently receiving radiation therapy in which pain intensity is quantified\n",
"population" : [
{
"id" : "InitialPopulation_2",
"code" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "initial-population",
"display" : "Initial Population"
}
]
},
"description" : "All patient visits, regardless of patient age, with a diagnosis of cancer currently receiving radiation therapy\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Initial Population 2"
}
},
{
"id" : "Denominator_2",
"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 2"
}
},
{
"id" : "Numerator_2",
"code" : {
"coding" : [
{
"system" : "http://terminology.hl7.org/CodeSystem/measure-population",
"code" : "numerator",
"display" : "Numerator"
}
]
},
"description" : "Patient visits in which pain intensity is quantified\n",
"criteria" : {
"language" : "text/cql-identifier",
"expression" : "Numerator 2"
}
}
]
}
],
"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"
}
}
]
}