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

: NHSN Glycemic Control Hypoglycemia Initial Population - JSON Representation

Active as of 2025-08-21

Raw json | Download

{
  "resourceType" : "Measure",
  "id" : "NHSNGlycemicControlHypoglycemiaInitialPopulation",
  "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/cohort-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\">NHSN Glycemic Control Hypoglycemia Initial Population</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\">0.0.003</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\">NHSNHypoglycemia</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:0d555fb6-f654-418c-a2b3-2dd0c3f0e7b4</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:dc9459ed-48ca-45f3-923e-3352d9547461</td>\n</tr>\n\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<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Use Context</th>\n\n\n<td class=\"content-container\">org.hl7.fhir.r5.model.UsageContext@6a4e852b</td>\n</tr>\n\n\n\n\n\n\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Steward (Publisher)</th>\n\n\n<td class=\"content-container\">Centers for Disease Control and Prevention (CDC)</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\">Lantana Consulting Group</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>All inpatient encounters (including ED/Observation visits that end within 1 hour of the start of the inpatient encounter) for patients of all ages where at least one diabetes medication was ordered or administered during the encounter that is during the measurement period.</p></td>\n</tr>\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Purpose</th>\n\n\n<td class=\"content-container\"><p>The primary objective of the NHSN Glycemic Control module is to measure and benchmark medication-related hypoglycemia and hyperglycemia events within a facility. NHSN uses line-level data on medications and blood glucose reported by facilities to provide analytic reports to inform quality-improvement efforts for glycemic control and track patient safety events. As NHSN collects additional data, an additional objective will be to allow inter-facility benchmarking and evaluate national-level trends of medication-related hypoglycemia over time.</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>Limited proprietary coding is contained in the Measure specifications for user convenience. Users of proprietary code sets should obtain all necessary licenses from the owners of the code sets.</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>Disclaimer This performance 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 MEASURES AND SPECIFICATIONS ARE PROVIDED “AS IS” WITHOUT WARRANTY OF ANY KIND.</p>\n<p>This measure and specifications are subject to further revisions.</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>The NHSN Glycemic Control module supports an electronic health record (EHR)- and vendor-neutral standard for reporting patient-level, linked medication and blood glucose data for inpatients. These data support calculation of inpatient medication-related hypoglycemia events by the NHSN application, which are then returned as reports to the facility.</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\"><p>Inpatient hypoglycemia can be severe and life-threatening and is associated with longer hospital stays and increased medical costs (Wexler et al., 2007; Curkendall et al., 2009; Cook et al., 2009; Turchin et al., 2009; Egi et al., 2010). The prevalence of inpatient hypoglycemia varies with patient, hospital unit, timing of episodes, and glycemic threshold. Severe hypoglycemia (&lt;40 mg/dL) occurs in 2%–5% of hospitalized patients with diabetes mellitus (DM), while hypoglycemia &lt;70 mg/dL has been reported in up to 10% of all patients in the intensive care unit (Finfer et al., 2012). Patients with DM comprise more than 25% of all U.S. inpatient stays and medication-related hypoglycemia events are common causes of adverse drug events (ADEs) that occur in inpatient settings (Bates et al., 2023; Spector et al., 2017). Rates of severe hypoglycemia vary across hospitals, suggesting opportunities for improvement in glycemic-control quality of care (Hulkower et al., 2014; ADA, 2013; Cook et al., 2009).</p>\n<p>Inpatient hyperglycemia can increase morbidity, prolong hospital stays, and increase the risk of mortality (Maynard et al., 2014; SHM, n.d.; Umpierrez et al., 2002; Kyi et al., 2019; Pratiwi et al., 2021). The prevalence of inpatient hyperglycemia varies depending upon glycemic threshold and setting, but blood glucose &gt;140 mg/dL likely occurs in approximately one-eighth to one-quarter of hospitalized patients (Pratiwi et al., 2021; Seisa et al., 2022; Barmanray et al., 2024). Tracking patient blood-glucose levels and implementing appropriate interventions may reduce complications associated with both hyperglycemia and hypoglycemia (ADA, 2013; Cook et al., 2009; Korytkowski et al., 2022; Moghissi et al., 2009).</p></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    <p>American Diabetes Association. Economic costs of diabetes in the U.S. in 2012. Diabetes Care 2013;36:1033–46.</p>\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    <p>Bates, D. W., Levine, D. M., Salmasian, H., et al. (2023). The safety of inpatient health care. New England Journal of Medicine, 388(12), 142–153.</p>\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    <p>Classen, D. C., Resar, R., Griffin, F., et al. (2011). 'Global trigger tool' shows that adverse events in hospitals may be ten times greater than previously measured. Health Affairs, 30(4), 581–589.</p>\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    <p>Cook, C. B., Kongable, G. L., Potter, D. J., et al. (2009). Inpatient glucose control: A glycemic survey of 126 U.S. hospitals. Journal of Hospital Medicine, 4(E7), E7–E14.</p>\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    <p>Curkendall, S. M., Natoli, J. L., Alexander, C. M., et al. (2009). Economic and clinical impact of inpatient diabetic hypoglycemia. Endocrine Practice, 15(3), 302–312.</p>\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    <p>Egi, M., Bellomo, R., Stachowski, E., et al. (2010). Hypoglycemia and outcome in critically ill patients. Mayo Clinic Proceedings, 85(3), 217–224.</p>\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    <p>Finfer, S., Liu, B., Chittock, D. R., et al. (2012). Hypoglycemia and risk of death in critically ill patients. New England Journal of Medicine, 367, 1108–1118.</p>\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    <p>Gates, P. J., Meyerson, S. A., Baysari, M. T., et al. (2018). Preventable adverse drug events among inpatients: A systematic review. Pediatrics, 142, e20180805.</p>\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    <p>Hulkower RD, Pollack RM, Zonszein J. Understanding hypoglycemia in hospitalized patients. Diabetes Manag (Lond) 2014;4:165-76.</p>\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    <p>Maynard, G., et al. (2014). How sweet is it? The use of benchmarking to optimize inpatient glycemic control. Diabetes Spectrum, 27, 212–217.</p>\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    <p>Moghissi ES, Korytkowski MT, DiNardo M. American Association of Clinical Endocrinologists and American Diabetes Association consensus statement on inpatient glycemic control. Endocr Pract 2009;15:353-69.</p>\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    <p>Society of Hospital Medicine. Glycemic Control for Hospitalists. Optimizing Care, Preventing Hypoglycemia. Available at: https://www.hospitalmedicine.org/clinical-topics/glycemic-control.</p>\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    <p>Spector, W. D., Limcangco, R., Furukawa, M. F., Encinosa, W. E. (2017). The marginal costs of adverse drug events associated with exposures to anticoagulants and hypoglycemic agents during hospitalization. Medical Care, 55(8), 856–863.</p>\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    <p>Turchin, A., Matheny, M. E., Shubina, M., et al. (2009). Hypoglycemia and clinical outcomes in patients with diabetes hospitalized in the general ward. Diabetes Care, 32(7), 1153–1157.</p>\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    <p>Umpierrez, G. E., Isaacs, S. D., Bazargan, N., et al. (2002). Hyperglycemia: An independent marker of in-hospital mortality in patients with undiagnosed diabetes. Journal of Clinical Endocrinology &amp; Metabolism, 87(3), 978–982.</p>\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    <p>Wexler, D. J., et al. (2007). Prevalence of hyper- and hypoglycemia among inpatients with diabetes: A national survey of 44 U.S. hospitals. Diabetes Care, 30(2), 367–369.</p>\n    \n    \n    \n    \n    \n  </td>\n</tr>\n\n\n\n\n\n\n  \n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Blood glucose: <p>Blood-glucose data refers to data from random, periprandial, or fasting tests; from capillary, serum, plasma, interstitial fluid, or whole-blood sources; using central laboratory device (CLD) or point-of-care (POC) testing. Data from continuous glucose monitoring (CGM) systems can only be captured if they are integrated into the EHR and exposed in the corresponding FHIR resources. Post-glucose administration tests are excluded. Events are based on the day/time the laboratory test was collected (drawn). If day/time collected is not available, the day/time the lab was ordered is used.</p></td>\n</tr>\n\n\n  \n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Emergency department (ED)/Observation (Obs) encounter: <p>Any patient visit to an ED or observation location. One (1) patient visit equals one (1) encounter. ED/Observation encounters are considered outpatient locations.</p></td>\n</tr>\n\n\n  \n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Hypoglycemic medication: <p>All currently and previously commercially available oral or injectable hypoglycemic medications in the United States.</p></td>\n</tr>\n\n\n  \n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Inpatient encounter: <p>Includes all encounters in inpatient locations.</p></td>\n</tr>\n\n\n  \n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Mild hypoglycemia event: <p>Blood glucose 54.0 mg/dL to 69.9 mg/dL as identified on CLD or prescription POC device with no subsequent repeat test for blood glucose with a result &gt; 80 mg/dL within 5 minutes of the start of the initial low blood glucose test.</p></td>\n</tr>\n\n\n  \n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Moderate hypoglycemia event: <p>Blood glucose 40.0 mg/dL to 53.9 mg/dL as identified on CLD or prescription POC device with no subsequent repeat test for blood glucose with a result &gt; 80 mg/dL within 5 minutes of the start of the initial low blood glucose test.</p></td>\n</tr>\n\n\n  \n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Definition</th>\n\n\n<td class=\"content-container\">Severe hypoglycemia event: <p>Blood glucose &lt; 40.0 mg/dL as identified on CLD or prescription POC device with no subsequent repeat test for blood glucose with a result &gt; 80 mg/dL within 5 minutes of the start of the initial low blood glucose test.</p></td>\n</tr>\n\n\n\n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Guidance (Usage)</th>\n\n\n<td class=\"content-container\"><p>All participating inpatient facilities reporting data to the NHSN Glycemic Control module must be able to report data electronically in adherence to HL7 FHIR US Core FHIR R4.0.1 data standards and specifications and NHSN instructions for reporting dQMs, including the HL7 NHSN dQM Reporting Implementation Guide (https://build.fhir.org/ig/HL7/nhsn-dqm/).</p></td>\n</tr>\n\n\n\n  \n    \n    <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Measure Group (Rate) (ID: Group_1)</th>\n\n\n</tr>\n  \n  \n  \n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Basis</th>\n\n\n<td class=\"content-container\">Encounter</td>\n</tr>\n\n\n\n  \n<tr>\n\n\n<th scope=\"row\" class=\"row-header\">Scoring</th>\n\n\n<td class=\"content-container\">[http://terminology.hl7.org/CodeSystem/measure-scoring#cohort: 'Cohort']</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  \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 inpatient encounters, as well as ED and OBS encounters that end within 1 hour of the start of the inpatient encounter, for patients of all ages where at least one diabetes medication was ordered or administered during the encounter that is during the measurement period.</p></p>\n        \n        \n          \n            \n            <em>Logic Definition</em>: <a href=\"#primary-nhsnglycemiccontrolhypoglycemiainitialpopulation-initial-population\">Initial Population</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\"><p>Supplemental Data</p></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-encounter-locations\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 Encounter Locations\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-encounter-locations\">SDE Encounter Locations</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-location\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 Location\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-location\">SDE Location</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-medication\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 Medication\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-medication\">SDE Medication</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-blood-glucose-observation\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 Blood Glucose Observation\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-blood-glucose-observation\">SDE Blood Glucose Observation</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-chief-complaint\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 Chief Complaint\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-chief-complaint\">SDE Chief Complaint</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-condition\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 Condition\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-condition\">SDE Condition</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-coverage\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 Coverage\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-coverage\">SDE Coverage</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-initial-population-encounters\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 Initial Population Encounters\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-initial-population-encounters\">SDE Initial Population Encounters</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-medication-administration\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 Medication Administration\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-medication-administration\">SDE Medication Administration</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-medication-request\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 Medication Request\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-medication-request\">SDE Medication Request</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-minimal-patient\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 Minimal Patient\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-minimal-patient\">SDE Minimal Patient</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-service-request\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 Service Request\n    \n    \n      \n        <br/>\n        \n        <em>Logic Definition</em>: <a href=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-service-request\">SDE Service Request</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-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=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-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=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-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=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-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=\"#nhsnglycemiccontrolhypoglycemiainitialpopulation-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/NHSNGlycemicControlHypoglycemiaInitialPopulation</td>\n</tr>\n\n\n\n\n<tr>\n  <th scope=\"row\" class=\"row-header\">Contents</th>\n  <td class=\"content-container\">\n    <em><a href=\"#population-criteria\">Population Criteria</a></em>\n    <br/>\n    <em><a href=\"#definitions\">Logic Definitions</a></em>\n    <br/>\n    <em><a href=\"#terminology\">Terminology</a></em>\n    <br/>\n    <em><a href=\"#dependencies\">Dependencies</a></em>\n    <br/>\n    <em><a href=\"#data-requirements\">Data Requirements</a></em>\n    <br/>\n  </td>\n</tr>\n\n\n  <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"population-criteria\"> </a>Population Criteria</th>\n\n\n</tr>\n  \n  \n  \n  \n    \n    <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\">Measure Group (Rate) (ID: Group_1)</th>\n\n\n</tr>\n  \n  \n  \n  \n    \n      \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n            \n              \n            \n            <tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"primary-nhsnglycemiccontrolhypoglycemiainitialpopulation-initial-population\"> </a>\n    \n    \n    Initial Population\n    \n  </th>\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">// Initial Population\n\n\ndefine &quot;Initial Population&quot;:\n  ( &quot;Inpatient Encounters During Measurement Period&quot;\n    union &quot;Encounters with Patient Hospital Locations&quot; ) InpatientEncounters\n    with &quot;Antidiabetic Drugs Administered or Ordered&quot; ADD\n      such that Coalesce(start of ADD.effective.toInterval(), ADD.authoredOn) during InpatientEncounters.&quot;hospitalizationWithObservation&quot; ( )\n    where ( InpatientEncounters.status = 'finished'\n        or InpatientEncounters.status = 'in-progress'\n        or InpatientEncounters.status = 'triaged'\n        or InpatientEncounters.status = 'onleave'\n        or InpatientEncounters.status = 'entered-in-error'\n    )</code></pre>\n  </td>\n\n</tr>\n\n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n          \n        \n      \n    \n  \n\n  \n  \n\n  \n  \n\n\n  <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\n        \n\n\n\n        \n\n\n\n        \n\n\n\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-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 &quot;SDE Race&quot;:\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<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 &quot;SDE Sex&quot;:\n  case\n    when Patient.sex = '248153007' then &quot;Male (finding)&quot;\n    when Patient.sex = '248152002' then &quot;Female (finding)&quot;\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<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 &quot;SDE Payer&quot;:\n  [Coverage: type in &quot;Payer Type&quot;] Payer\n    return {\n      code: Payer.type,\n      period: Payer.period\n    }</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"supplementaldataelements-sde-ethnicity\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> SupplementalDataElements</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define &quot;SDE Ethnicity&quot;:\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\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n\n        \n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"cqmcommon-getlocation\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns the Location resource specified by the given reference.\n*/\ndefine fluent function getLocation(reference Reference):\n  singleton from (\n    [Location] L where reference.references(L)\n  )</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"cqmcommon-getmedicationcode\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns the medication code for the given MedicationRequest\n*/\ndefine fluent function getMedicationCode(request MedicationRequest):\n  if request.medication is Concept then\n  \t  request.medication as Concept\n  \telse\n  \t  (singleton from ([Medication] M where request.medication.references(M))).code</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"cqmcommon-hospitalizationwithobservation\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> CQMCommon</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Hospitalization with Observation returns the total interval from the start of any immediately prior emergency department visit through the observation visit to the discharge of the given encounter\n*/\ndefine fluent function hospitalizationWithObservation(TheEncounter Encounter ):\n  TheEncounter Visit\n  \t\tlet ObsVisit: Last([Encounter: &quot;Observation Services&quot;] LastObs\n  \t\t\t\twhere LastObs.status = 'finished'\n            and LastObs.period ends 1 hour or less on or before start of Visit.period\n  \t\t\t\tsort by end of period\n  \t\t\t),\n  \t\t\tVisitStart: Coalesce(start of ObsVisit.period, start of Visit.period),\n  \t\t\tEDVisit: Last([Encounter: &quot;Emergency Department Visit&quot;] LastED\n  \t\t\t\twhere LastED.status = 'finished'\n            and LastED.period ends 1 hour or less on or before VisitStart\n  \t\t\t\tsort by end of period\n  \t\t\t)\n  \t\treturn Interval[Coalesce(start of EDVisit.period, VisitStart), end of Visit.period]</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n\n        \n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\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.&quot;start&quot; is null then\n            Interval(period.&quot;start&quot;.value, period.&quot;end&quot;.value]\n        else\n            Interval[period.&quot;start&quot;.value, period.&quot;end&quot;.value]</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"fhirhelpers-toconcept\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> FHIRHelpers</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Converts the given FHIR [CodeableConcept](https://hl7.org/fhir/datatypes.html#CodeableConcept) value to a CQL Concept.\n*/\ndefine function ToConcept(concept FHIR.CodeableConcept):\n    if concept is null then\n        null\n    else\n        System.Concept {\n            codes: concept.coding C return ToCode(C),\n            display: concept.text.value\n        }</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"fhirhelpers-tocode\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> FHIRHelpers</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Converts the given FHIR [Coding](https://hl7.org/fhir/datatypes.html#Coding) value to a CQL Code.\n*/\ndefine function ToCode(coding FHIR.Coding):\n    if coding is null then\n        null\n    else\n        System.Code {\n          code: coding.code.value,\n          system: coding.system.value,\n          version: coding.version.value,\n          display: coding.display.value\n        }</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n<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\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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-inpatient-encounters-during-measurement-period\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;Inpatient Encounters During Measurement Period&quot;:\n  [Encounter: &quot;Encounter Inpatient&quot;] InpatientEncounters\n    where InpatientEncounters.period ends during day of &quot;Measurement Period&quot;\n      and ( InpatientEncounters.class ~ QICoreCommon.&quot;inpatient non-acute&quot;\n          or InpatientEncounters.class ~ QICoreCommon.&quot;inpatient non-acute&quot;\n          or InpatientEncounters.class ~ QICoreCommon.&quot;short stay&quot;\n          or InpatientEncounters.class ~ QICoreCommon.&quot;inpatient acute&quot;\n          or InpatientEncounters.class ~ QICoreCommon.&quot;inpatient encounter&quot;\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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-encounters-with-patient-hospital-locations\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;Encounters with Patient Hospital Locations&quot;:\n  &quot;Inpatient Encounters During Measurement Period&quot; InpatientEncounter\n    where exists ( InpatientEncounter.location HospitalLocation\n        where HospitalLocation.location.getLocation ( ).type in &quot;Inpatient, Emergency, and Observation Locations&quot;\n          and HospitalLocation.period during day of InpatientEncounter.period\n    )</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-medicationrequests\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;MedicationRequests&quot;:\n  [MedicationRequest]</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-medicationadministrations\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;MedicationAdministrations&quot;:\n  [MedicationAdministration]</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-antidiabetic-drugs-administered-or-ordered\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;Antidiabetic Drugs Administered or Ordered&quot;:\n  ( &quot;MedicationRequests&quot;\n    union &quot;MedicationAdministrations&quot; ) MedReqOrAdmin\n    where Coalesce(MedReqOrAdmin.getMedicationCode(), MedReqOrAdmin.getMedicationAdministrationCode()) in &quot;Diabetes Medications&quot;</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-initial-population\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">// Initial Population\n\n\ndefine &quot;Initial Population&quot;:\n  ( &quot;Inpatient Encounters During Measurement Period&quot;\n    union &quot;Encounters with Patient Hospital Locations&quot; ) InpatientEncounters\n    with &quot;Antidiabetic Drugs Administered or Ordered&quot; ADD\n      such that Coalesce(start of ADD.effective.toInterval(), ADD.authoredOn) during InpatientEncounters.&quot;hospitalizationWithObservation&quot; ( )\n    where ( InpatientEncounters.status = 'finished'\n        or InpatientEncounters.status = 'in-progress'\n        or InpatientEncounters.status = 'triaged'\n        or InpatientEncounters.status = 'onleave'\n        or InpatientEncounters.status = 'entered-in-error'\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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-coverage\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Coverage&quot;:\n  [Coverage] Coverages\n    where exists ( &quot;Initial Population&quot; IP\n        where Coverages.period starts before or on day of IP.period\n          and end of Coverages.period on or after day of end of IP.period\n    )\n    return { Coverages.id, Coverages.meta, Coverages.status, Coverages.type, Coverages.policyHolder, Coverages.subscriber, Coverages.subscriberId, Coverages.beneficiary, Coverages.dependent, Coverages.relationship, Coverages.period, Coverages.payor, Coverages.class, Coverages.order, Coverages.network, Coverages.subrogation, Coverages.contract }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-medication-request\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Medication Request&quot;:\n  &quot;MedicationRequests&quot; MedRequests\n    where exists ( &quot;Initial Population&quot; InitialPopulation\n        where MedRequests.authoredOn during InitialPopulation.&quot;hospitalizationWithObservation&quot; ( )\n    )\n    return { MedRequests.id, MedRequests.meta, MedRequests.status, MedRequests.statusReason, MedRequests.intent, MedRequests.category, MedRequests.priority, MedRequests.doNotPerform, MedRequests.reported, MedRequests.medication, MedRequests.subject, MedRequests.encounter, MedRequests.authoredOn, MedRequests.requester, MedRequests.recorder, MedRequests.reasonCode, MedRequests.reasonReference, MedRequests.instantiatesCanonical, MedRequests.instantiatesUri, MedRequests.courseOfTherapyType, MedRequests.dosageInstruction }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-encounter-locations\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Encounter Locations&quot;:\n  &quot;Initial Population&quot; IP\n    where exists ( IP.location InitialPopulationLocation\n        let types: ( InitialPopulationLocation.location ).getLocation ( ).type\n        where exists ( types type\n            where type in &quot;Inpatient, Emergency, and Observation Locations&quot;\n        )\n          and InitialPopulationLocation.period during IP.period\n    )\n    return { IP.id, IP.meta, IP.identifier, IP.status, IP.statusHistory, IP.class, IP.classHistory, IP.type, IP.serviceType, IP.priority, IP.subject, IP.period, IP.length, IP.reasonCode, IP.reasonReference, IP.diagnosis, IP.account, IP.hospitalization, IP.location, IP.partOf }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-race\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Race&quot;:\n  SDE.&quot;SDE Race&quot;</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-medication-administration\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Medication Administration&quot;:\n  &quot;MedicationAdministrations&quot; MedAdministrations\n    where exists ( &quot;Initial Population&quot; InitialPopulation\n        where MedAdministrations.effective.toInterval ( ) overlaps InitialPopulation.&quot;hospitalizationWithObservation&quot; ( )\n    )\n    return { MedAdministrations.id, MedAdministrations.meta, MedAdministrations.instantiates, MedAdministrations.partOf, MedAdministrations.status, MedAdministrations.statusReason, MedAdministrations.category, MedAdministrations.medication, MedAdministrations.subject, MedAdministrations.context, MedAdministrations.supportingInformation, MedAdministrations.effective, MedAdministrations.performer, MedAdministrations.reasonCode, MedAdministrations.reasonReference, MedAdministrations.request, MedAdministrations.device, MedAdministrations.note, MedAdministrations.dosage }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-sex\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Sex&quot;:\n  SDE.&quot;SDE Sex&quot;</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-initial-population-encounters\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Initial Population Encounters&quot;:\n  &quot;Initial Population&quot; IP\n    return { IP.id, IP.meta, IP.identifier, IP.status, IP.statusHistory, IP.class, IP.classHistory, IP.type, IP.serviceType, IP.priority, IP.subject, IP.period, IP.length, IP.reasonCode, IP.reasonReference, IP.diagnosis, IP.account, IP.hospitalization, IP.location, IP.partOf }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-blood-glucose-observation\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">//Supplemental Data Elements\n\n\ndefine &quot;SDE Blood Glucose Observation&quot;:\n  ( [&quot;LaboratoryResultObservation&quot;: &quot;Blood Glucose Laboratory and Point of Care Tests&quot;] GlucoseTest\n      where exists ( &quot;Initial Population&quot; InitialPopulation\n          where start of GlucoseTest.effective.toInterval ( ) during day of InitialPopulation.period\n            or GlucoseTest.issued during day of InitialPopulation.period\n      )\n      return { GlucoseTest.id, GlucoseTest.extension, GlucoseTest.text, GlucoseTest.referenceRange, GlucoseTest.component, GlucoseTest.basedOn, GlucoseTest.partOf, GlucoseTest.category, GlucoseTest.status, GlucoseTest.subject, GlucoseTest.focus, GlucoseTest.encounter, GlucoseTest.effective, GlucoseTest.issued, GlucoseTest.performer, GlucoseTest.value, GlucoseTest.dataAbsentReason, GlucoseTest.interpretation, GlucoseTest.note, GlucoseTest.bodySite, GlucoseTest.method, GlucoseTest.specimen, GlucoseTest.device, GlucoseTest.hasMember, GlucoseTest.derivedFrom }\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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-condition\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Condition&quot;:\n  [&quot;ConditionProblemsHealthConcerns&quot;] Diagnosis\n    where exists ( &quot;Initial Population&quot; IP\n        where Diagnosis.prevalenceInterval ( ) overlaps day of IP.period\n    )\n    return { Diagnosis.id, Diagnosis.meta, Diagnosis.clinicalStatus, Diagnosis.verificationStatus, Diagnosis.category, Diagnosis.severity, Diagnosis.code, Diagnosis.bodySite, Diagnosis.subject, Diagnosis.encounter.reference.getId ( ), Diagnosis.onset, Diagnosis.stage, Diagnosis.evidence, Diagnosis.note }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-payer\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Payer&quot;:\n  SDE.&quot;SDE Payer&quot;</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-ethnicity\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Ethnicity&quot;:\n  SDE.&quot;SDE Ethnicity&quot;</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-get-locations-from-initial-population\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;Get Locations from Initial Population&quot;:\n  flatten ( &quot;Initial Population&quot; IP\n      let locationElements: IP.location\n      return locationElements LE\n        let locationReference: LE.location\n        return ( locationReference.getLocation ( ) )\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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-location\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Location&quot;:\n  &quot;Get Locations from Initial Population&quot; Locations\n    where exists &quot;Initial Population&quot;\n      and Locations is not null\n    return { Locations.id, Locations.meta, Locations.extension, Locations.status, Locations.operationalStatus, Locations.name, Locations.alias, Locations.description, Locations.mode, Locations.type, Locations.telecom, Locations.address, Locations.physicalType, Locations.position, Locations.managingOrganization, Locations.partOf, Locations.hoursOfOperation, Locations.availabilityExceptions, Locations.endpoint }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-service-request\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Service Request&quot;:\n  [ServiceRequest] ServiceRequests\n    where exists ( &quot;Initial Population&quot; InitialPopulation\n        where ServiceRequests.authoredOn during InitialPopulation.period\n    )\n    return { ServiceRequests.id, ServiceRequests.meta, ServiceRequests.instantiatesCanonical, ServiceRequests.instantiatesUri, ServiceRequests.basedOn, ServiceRequests.replaces, ServiceRequests.requisition, ServiceRequests.status, ServiceRequests.intent, ServiceRequests.category, ServiceRequests.priority, ServiceRequests.doNotPerform, ServiceRequests.code, ServiceRequests.orderDetail, ServiceRequests.quantity, ServiceRequests.subject, ServiceRequests.encounter, ServiceRequests.occurrence, ServiceRequests.asNeeded, ServiceRequests.authoredOn, ServiceRequests.requester, ServiceRequests.performerType, ServiceRequests.performer, ServiceRequests.locationCode, ServiceRequests.reasonCode, ServiceRequests.reasonReference, ServiceRequests.insurance, ServiceRequests.bodySite, ServiceRequests.note, ServiceRequests.patientInstruction }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-minimal-patient\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Minimal Patient&quot;:\n  [Patient] MinPt\n    where exists &quot;Initial Population&quot;\n    return { MinPt.id, MinPt.meta, MinPt.extension, MinPt.identifier, MinPt.active, MinPt.name, MinPt.telecom, MinPt.gender, MinPt.birthDate, MinPt.deceased, MinPt.address, MinPt.maritalStatus, MinPt.multipleBirth, MinPt.photo, MinPt.contact, MinPt.communication, MinPt.generalPractitioner, MinPt.managingOrganization, MinPt.link }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-medication\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Medication&quot;:\n  ( &quot;MedicationRequests&quot;\n    union &quot;MedicationAdministrations&quot; ) MedReqOrAdmin\n    let medication: GetMedication(MedReqOrAdmin.medication as Reference)\n    where medication is not null\n      and exists ( &quot;Initial Population&quot; IP\n          where Coalesce(MedReqOrAdmin.effective.toInterval(), MedReqOrAdmin.authoredOn.toInterval()) overlaps IP.&quot;hospitalizationWithObservation&quot; ( )\n      )\n    return { medication.id, medication.meta, medication.code, medication.status, medication.manufacturer, medication.form, medication.amount, medication.ingredient, medication.batch }</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=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-sde-chief-complaint\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;SDE Chief Complaint&quot;:\n  &quot;Initial Population&quot; IP\n    where exists ( IP.diagnosis InitialPopulationDiagnosis\n        where InitialPopulationDiagnosis.use ~ QICoreCommon.&quot;CC&quot;\n    )\n    return { IP.id, IP.meta, IP.identifier, IP.status, IP.statusHistory, IP.class, IP.classHistory, IP.type, IP.serviceType, IP.priority, IP.subject, IP.period, IP.length, IP.reasonCode, IP.reasonReference, IP.diagnosis, IP.account, IP.hospitalization, IP.location, IP.partOf }</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<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-getmedicationadministrationcode\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">define fluent function getMedicationAdministrationCode(admin MedicationAdministration):\n  if admin.medication is Concept then admin.medication as Concept \n    else ( singleton from ( [Medication] M\n        where admin.medication.references ( M )\n    )\n  ).code</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<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"nhsnglycemiccontrolhypoglycemiainitialpopulation-getmedication\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> NHSNGlycemicControlHypoglycemiaInitialPopulation</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 &quot;GetMedication&quot;(reference Reference):\n  singleton from ( [Medication] Medication\n      where reference.references ( Medication )\n  )</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n\n        \n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"qicorecommon-references\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> QICoreCommon</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns true if the given reference is to the given resource\n@comment: Returns true if the `id` element of the given resource exactly equals the tail of the given reference.\nNOTE: This function assumes resources from the same source server.\n*/\ndefine fluent function references(reference Reference, resource Resource):\n  resource.id = Last(Split(reference.reference, '/'))</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"qicorecommon-prevalenceinterval\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> QICoreCommon</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns an interval representing the normalized prevalence period of a given Condition.\n@comment: Uses the ToInterval and ToAbatementInterval functions to determine the widest potential interval from\nonset to abatement as specified in the given Condition. If the condition is active, or has an abatement date the resulting \ninterval will have a closed ending boundary. Otherwise, the resulting interval will have an open ending boundary.\n*/\ndefine fluent function prevalenceInterval(condition Choice&lt;&quot;ConditionEncounterDiagnosis&quot;, &quot;ConditionProblemsHealthConcerns&quot;&gt;):\nif condition.clinicalStatus ~ &quot;active&quot;\n  or condition.clinicalStatus ~ &quot;recurrence&quot;\n  or condition.clinicalStatus ~ &quot;relapse&quot; then\n  Interval[start of condition.onset.toInterval(), end of condition.abatementInterval()]\nelse\n    (end of condition.abatementInterval()) abatementDate\n    return if abatementDate is null then\n      Interval[start of condition.onset.toInterval(), abatementDate)\n    else\n      Interval[start of condition.onset.toInterval(), abatementDate]</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"qicorecommon-abatementinterval\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> QICoreCommon</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns an interval representing the normalized abatement of a given Condition.\n@comment: If the abatement element of the Condition is represented as a DateTime, the result\nis an interval beginning and ending on that DateTime.\nIf the abatement is represented as a Quantity, the quantity is expected to be a calendar-duration and is interpreted as the age of the patient. The\nresult is an interval from the date the patient turned that age to immediately before one year later.\nIf the abatement is represented as a Quantity Interval, the quantities are expected to be calendar-durations and are interpreted as an age range during\nwhich the abatement occurred. The result is an interval from the date the patient turned the starting age of the quantity interval, and ending immediately\nbefore one year later than the date the patient turned the ending age of the quantity interval.\n*/\ndefine fluent function abatementInterval(condition Choice&lt;&quot;ConditionEncounterDiagnosis&quot;, &quot;ConditionProblemsHealthConcerns&quot;&gt;):\n\tif condition.abatement is DateTime then\n\t  Interval[condition.abatement as DateTime, condition.abatement as DateTime]\n\telse if condition.abatement is Quantity then\n\t\tInterval[Patient.birthDate + (condition.abatement as Quantity),\n\t\t\tPatient.birthDate + (condition.abatement as Quantity) + 1 year)\n\telse if condition.abatement is Interval&lt;Quantity&gt; then\n\t  Interval[Patient.birthDate + (condition.abatement.low as Quantity),\n\t\t  Patient.birthDate + (condition.abatement.high as Quantity) + 1 year)\n\telse if condition.abatement is Interval&lt;DateTime&gt; then\n\t  Interval[condition.abatement.low, condition.abatement.high)\n\telse null as Interval&lt;DateTime&gt;</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"qicorecommon-getid\"> </a>\n    \n    Logic Definition\n  </th>\n\n  <td class=\"content-container\"><em>Library Name:</em> QICoreCommon</td>\n\n</tr>\n<tr>\n\n  <td>\n    <pre style=\"border: none;\" class=\"content-container highlight language-cql\"><code class=\"language-cql\">/*\n@description: Returns the tail of the given uri (i.e. everything after the last slash in the URI).\n@comment: This function can be used to determine the logical id of a given resource. It can be used in\na single-server environment to trace references. However, this function does not attempt to resolve\nor distinguish the base of the given url, and so cannot be used safely in multi-server environments.\n*/\ndefine fluent function getId(uri String):\n  Last(Split(uri, '/'))</code></pre>\n  </td>\n\n</tr>\n\n\n\n        \n\n\n\n        \n\n\n<tr>\n  <th scope=\"row\" rowspan=\"2\" class=\"row-header\">\n    \n      \n      <a name=\"qicorecommon-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&lt;DateTime&gt;, or Interval&lt;Quantity&gt; 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&lt;DateTime&gt; or Interval&lt;Quantity&gt;.\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&lt;DateTime, Quantity, Interval&lt;DateTime&gt;, Interval&lt;Quantity&gt;, Timing&gt;):\n  case\n\t  when choice is DateTime then\n    \tInterval[choice as DateTime, choice as DateTime]\n\t\twhen choice is Interval&lt;DateTime&gt; then\n  \t\tchoice as Interval&lt;DateTime&gt;\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&lt;Quantity&gt; 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&lt;DateTime&gt;\n\t\telse\n\t\t\tnull as Interval&lt;DateTime&gt;\n\tend</code></pre>\n  </td>\n\n</tr>\n\n\n\n\n\n  \n  \n\n\n  <tr>\n\n\n<th colspan=\"2\" scope=\"row\" class=\"row-header\"><a name=\"terminology\"> </a>Terminology</th>\n\n\n</tr>\n  \n  \n  \n\n \n\n \n\n \n\n \n\n \n\n\n<tr>\n  \n  \n  \n\n<th scope=\"row\" class=\"row-header\">Code System</th>\n\n\n  \n  <td class=\"content-container\">\n    \n    <em>Description</em>: Code system ActCode\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: http://terminology.hl7.org/CodeSystem/v3-ActCode\n    <br/>\n    <em>Canonical URL</em>: <tt>http://terminology.hl7.org/CodeSystem/v3-ActCode</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 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 ConditionClinicalStatusCodes\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: http://terminology.hl7.org/CodeSystem/condition-clinical\n    <br/>\n    <em>Canonical URL</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</tt>\n    \n  </td>\n</tr>\n \n\n\n<tr>\n  \n  \n  \n\n<th scope=\"row\" class=\"row-header\">Code System</th>\n\n\n  \n  <td class=\"content-container\">\n    \n    <em>Description</em>: Code system Diagnosis Role\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: http://terminology.hl7.org/CodeSystem/diagnosis-role\n    <br/>\n    <em>Canonical URL</em>: <tt>http://terminology.hl7.org/CodeSystem/diagnosis-role</tt>\n    \n  </td>\n</tr>\n \n\n\n<tr>\n  \n  \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n  \n  \n  <td class=\"content-container\">\n    \n    <em>Description</em>: Value set Encounter Inpatient\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307\n    <br/>\n    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307</tt>\n    \n  </td>\n</tr>\n \n\n\n<tr>\n  \n  \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n  \n  \n  <td class=\"content-container\">\n    \n    <em>Description</em>: Value set Inpatient, Emergency, and Observation Locations\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.265\n    <br/>\n    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.265</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 Diabetes Medications\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1190.58\n    <br/>\n    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1190.58</tt>\n    \n  </td>\n</tr>\n \n\n\n<tr>\n  \n  \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n  \n  \n  <td class=\"content-container\">\n    \n    <em>Description</em>: Value set Observation Services\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143\n    <br/>\n    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143</tt>\n    \n  </td>\n</tr>\n \n\n\n<tr>\n  \n  \n\n<th scope=\"row\" class=\"row-header\">Value Set</th>\n\n\n  \n  \n  <td class=\"content-container\">\n    \n    <em>Description</em>: Value set Emergency Department 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.117.1.7.1.292\n    <br/>\n    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292</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 Blood Glucose Laboratory and Point of Care Tests\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1190.38\n    <br/>\n    <em>Canonical URL</em>: <tt>http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1190.38</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>: inpatient non-acute\n        <br/>\n      \n      <em>Code</em>: NONAC\n      <br/>\n      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/v3-ActCode</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>: short stay\n        <br/>\n      \n      <em>Code</em>: SS\n      <br/>\n      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/v3-ActCode</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>: inpatient acute\n        <br/>\n      \n      <em>Code</em>: ACUTE\n      <br/>\n      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/v3-ActCode</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>: inpatient encounter\n        <br/>\n      \n      <em>Code</em>: IMP\n      <br/>\n      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/v3-ActCode</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>: 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>: Active\n        <br/>\n      \n      <em>Code</em>: active\n      <br/>\n      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</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>: Recurrence\n        <br/>\n      \n      <em>Code</em>: recurrence\n      <br/>\n      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</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>: Relapse\n        <br/>\n      \n      <em>Code</em>: relapse\n      <br/>\n      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/condition-clinical</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>: Chief complaint\n        <br/>\n      \n      <em>Code</em>: CC\n      <br/>\n      <em>System</em>: <tt>http://terminology.hl7.org/CodeSystem/diagnosis-role</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 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<tr>\n  \n\n<th scope=\"row\" class=\"row-header\">Dependency</th>\n\n\n  <td class=\"content-container\">\n    \n    <em>Description</em>: Library CQMCommon\n    \n    <br/>\n    \n    \n    \n    \n    \n    \n    <em>Resource</em>: https://madie.cms.gov/Library/CQMCommon|4.1.000\n    <br/>\n    <em>Canonical URL</em>: <tt>https://madie.cms.gov/Library/CQMCommon|4.1.000</tt>\n    \n  </td>\n</tr>\n \n\n\n<tr>\n  \n\n<th scope=\"row\" class=\"row-header\">Dependency</th>\n\n\n  <td class=\"content-container\">\n    \n    <em>Description</em>: Library 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\n \n\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>: Encounter\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: type, status, status.value, period, location, id, id.value, meta, identifier, statusHistory, class, classHistory, serviceType, priority, subject, length, reasonCode, reasonReference, diagnosis, account, hospitalization, partOf\n    <br/>\n   \n  \n    <em>Code Filter(s)</em>: \n    <br/>\n  \n  \n    <span class=\"tab-one\"><em>Path</em>: type</span>\n    <br/>\n  \n  \n  \n    <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143\n    <br/> \n  \n  \n  \n   \n  </td>\n</tr>\n\n<tr>\n  <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n  <td class=\"content-container\">\n    <em>Type</em>: Encounter\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: type, status, status.value, period, location, id, id.value, meta, identifier, statusHistory, class, classHistory, serviceType, priority, subject, length, reasonCode, reasonReference, diagnosis, account, hospitalization, partOf\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.117.1.7.1.292\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, class, status, status.value, location, id, id.value, meta, identifier, statusHistory, classHistory, serviceType, priority, subject, length, reasonCode, reasonReference, diagnosis, account, hospitalization, partOf\n    <br/>\n   \n  \n    <em>Code Filter(s)</em>: \n    <br/>\n  \n  \n    <span class=\"tab-one\"><em>Path</em>: type</span>\n    <br/>\n  \n  \n  \n    <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307\n    <br/> \n  \n  \n  \n   \n  </td>\n</tr>\n\n<tr>\n  <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n  <td class=\"content-container\">\n    <em>Type</em>: Resource\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/StructureDefinition/Resource\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: id, id.value\n    <br/>\n   \n   \n  </td>\n</tr>\n\n<tr>\n  <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n  <td class=\"content-container\">\n    <em>Type</em>: Location\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-location\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: id, id.value, meta, extension, status, status.value, operationalStatus, name, name.value, alias, description, description.value, mode, mode.value, type, telecom, address, physicalType, position, managingOrganization, partOf, hoursOfOperation, availabilityExceptions, availabilityExceptions.value, endpoint\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>: MedicationRequest\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-medicationrequest\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: medication, authoredOn, authoredOn.value, id, id.value, meta, status, status.value, statusReason, intent, intent.value, category, priority, priority.value, doNotPerform, doNotPerform.value, reported, subject, encounter, requester, recorder, reasonCode, reasonReference, instantiatesCanonical, instantiatesUri, courseOfTherapyType, dosageInstruction\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>: MedicationAdministration\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-medicationadministration\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: medication, effective, id, id.value, meta, instantiates, partOf, status, status.value, statusReason, category, subject, context, supportingInformation, performer, reasonCode, reasonReference, request, device, note, dosage\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>: Medication\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-medication\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: code\n    <br/>\n   \n   \n  </td>\n</tr>\n\n<tr>\n  <th scope=\"row\" class=\"row-header\">Data Requirement</th>\n  <td class=\"content-container\">\n    <em>Type</em>: 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>: period, id, id.value, meta, status, status.value, type, policyHolder, subscriber, subscriberId, subscriberId.value, beneficiary, dependent, dependent.value, relationship, payor, class, order, order.value, network, network.value, subrogation, subrogation.value, contract\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>: 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<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>: url, extension, birthDate, birthDate.value, id, id.value, meta, identifier, active, active.value, name, telecom, gender, gender.value, deceased, address, maritalStatus, multipleBirth, photo, contact, communication, generalPractitioner, managingOrganization, link\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>: Observation\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-observation-lab\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: code, effective, issued, issued.value, id, id.value, extension, text, referenceRange, component, basedOn, partOf, category, status, status.value, subject, focus, encounter, performer, value, dataAbsentReason, interpretation, note, bodySite, method, specimen, device, hasMember, derivedFrom\n    <br/>\n   \n  \n    <em>Code Filter(s)</em>: \n    <br/>\n  \n  \n    <span class=\"tab-one\"><em>Path</em>: code</span>\n    <br/>\n  \n  \n  \n    <span class=\"tab-one\"><em>ValueSet</em>:</span> http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1190.38\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>: id, id.value, meta, clinicalStatus, verificationStatus, category, severity, code, bodySite, subject, encounter, encounter.reference, encounter.reference.value, onset, stage, evidence, note\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>: ServiceRequest\n    <br/>\n  \n    <em>Profile(s)</em>: \n  \n    http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-servicerequest\n    <br/>        \n  \n   \n   \n    <em>Must Support Elements</em>: authoredOn, authoredOn.value, id, id.value, meta, instantiatesCanonical, instantiatesUri, basedOn, replaces, requisition, status, status.value, intent, intent.value, category, priority, priority.value, doNotPerform, doNotPerform.value, code, orderDetail, quantity, subject, encounter, occurrence, asNeeded, requester, performerType, performer, locationCode, reasonCode, reasonReference, insurance, bodySite, note, patientInstruction, patientInstruction.value\n    <br/>\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://terminology.hl7.org/CodeSystem/v3-ActCode",
            "code" : "NONAC",
            "display" : "inpatient non-acute"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://terminology.hl7.org/CodeSystem/v3-ActCode",
            "code" : "SS",
            "display" : "short stay"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://terminology.hl7.org/CodeSystem/v3-ActCode",
            "code" : "ACUTE",
            "display" : "inpatient acute"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://terminology.hl7.org/CodeSystem/v3-ActCode",
            "code" : "IMP",
            "display" : "inpatient encounter"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://snomed.info/sct",
            "code" : "248153007",
            "display" : "Male (finding)"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://snomed.info/sct",
            "code" : "248152002",
            "display" : "Female (finding)"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://terminology.hl7.org/CodeSystem/condition-clinical",
            "code" : "active",
            "display" : "Active"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://terminology.hl7.org/CodeSystem/condition-clinical",
            "code" : "recurrence",
            "display" : "Recurrence"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://terminology.hl7.org/CodeSystem/condition-clinical",
            "code" : "relapse",
            "display" : "Relapse"
          }
        },
        {
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-directReferenceCode",
          "valueCoding" : {
            "system" : "http://terminology.hl7.org/CodeSystem/diagnosis-role",
            "code" : "CC",
            "display" : "Chief complaint"
          }
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "Inpatient Encounters During Measurement Period"
            },
            {
              "url" : "statement",
              "valueString" : "define \"Inpatient Encounters During Measurement Period\":\n  [Encounter: \"Encounter Inpatient\"] InpatientEncounters\n    where InpatientEncounters.period ends during day of \"Measurement Period\"\n      and ( InpatientEncounters.class ~ QICoreCommon.\"inpatient non-acute\"\n          or InpatientEncounters.class ~ QICoreCommon.\"inpatient non-acute\"\n          or InpatientEncounters.class ~ QICoreCommon.\"short stay\"\n          or InpatientEncounters.class ~ QICoreCommon.\"inpatient acute\"\n          or InpatientEncounters.class ~ QICoreCommon.\"inpatient encounter\"\n      )"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 0
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "Encounters with Patient Hospital Locations"
            },
            {
              "url" : "statement",
              "valueString" : "define \"Encounters with Patient Hospital Locations\":\n  \"Inpatient Encounters During Measurement Period\" InpatientEncounter\n    where exists ( InpatientEncounter.location HospitalLocation\n        where HospitalLocation.location.getLocation ( ).type in \"Inpatient, Emergency, and Observation Locations\"\n          and HospitalLocation.period during day of InpatientEncounter.period\n    )"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 1
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "MedicationRequests"
            },
            {
              "url" : "statement",
              "valueString" : "define \"MedicationRequests\":\n  [MedicationRequest]"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 2
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "MedicationAdministrations"
            },
            {
              "url" : "statement",
              "valueString" : "define \"MedicationAdministrations\":\n  [MedicationAdministration]"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 3
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "Antidiabetic Drugs Administered or Ordered"
            },
            {
              "url" : "statement",
              "valueString" : "define \"Antidiabetic Drugs Administered or Ordered\":\n  ( \"MedicationRequests\"\n    union \"MedicationAdministrations\" ) MedReqOrAdmin\n    where Coalesce(MedReqOrAdmin.getMedicationCode(), MedReqOrAdmin.getMedicationAdministrationCode()) in \"Diabetes Medications\""
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 4
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "Initial Population"
            },
            {
              "url" : "statement",
              "valueString" : "// Initial Population\n\n\ndefine \"Initial Population\":\n  ( \"Inpatient Encounters During Measurement Period\"\n    union \"Encounters with Patient Hospital Locations\" ) InpatientEncounters\n    with \"Antidiabetic Drugs Administered or Ordered\" ADD\n      such that Coalesce(start of ADD.effective.toInterval(), ADD.authoredOn) during InpatientEncounters.\"hospitalizationWithObservation\" ( )\n    where ( InpatientEncounters.status = 'finished'\n        or InpatientEncounters.status = 'in-progress'\n        or InpatientEncounters.status = 'triaged'\n        or InpatientEncounters.status = 'onleave'\n        or InpatientEncounters.status = 'entered-in-error'\n    )"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 5
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Coverage"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Coverage\":\n  [Coverage] Coverages\n    where exists ( \"Initial Population\" IP\n        where Coverages.period starts before or on day of IP.period\n          and end of Coverages.period on or after day of end of IP.period\n    )\n    return { Coverages.id, Coverages.meta, Coverages.status, Coverages.type, Coverages.policyHolder, Coverages.subscriber, Coverages.subscriberId, Coverages.beneficiary, Coverages.dependent, Coverages.relationship, Coverages.period, Coverages.payor, Coverages.class, Coverages.order, Coverages.network, Coverages.subrogation, Coverages.contract }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 6
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Medication Request"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Medication Request\":\n  \"MedicationRequests\" MedRequests\n    where exists ( \"Initial Population\" InitialPopulation\n        where MedRequests.authoredOn during InitialPopulation.\"hospitalizationWithObservation\" ( )\n    )\n    return { MedRequests.id, MedRequests.meta, MedRequests.status, MedRequests.statusReason, MedRequests.intent, MedRequests.category, MedRequests.priority, MedRequests.doNotPerform, MedRequests.reported, MedRequests.medication, MedRequests.subject, MedRequests.encounter, MedRequests.authoredOn, MedRequests.requester, MedRequests.recorder, MedRequests.reasonCode, MedRequests.reasonReference, MedRequests.instantiatesCanonical, MedRequests.instantiatesUri, MedRequests.courseOfTherapyType, MedRequests.dosageInstruction }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 7
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Encounter Locations"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Encounter Locations\":\n  \"Initial Population\" IP\n    where exists ( IP.location InitialPopulationLocation\n        let types: ( InitialPopulationLocation.location ).getLocation ( ).type\n        where exists ( types type\n            where type in \"Inpatient, Emergency, and Observation Locations\"\n        )\n          and InitialPopulationLocation.period during IP.period\n    )\n    return { IP.id, IP.meta, IP.identifier, IP.status, IP.statusHistory, IP.class, IP.classHistory, IP.type, IP.serviceType, IP.priority, IP.subject, IP.period, IP.length, IP.reasonCode, IP.reasonReference, IP.diagnosis, IP.account, IP.hospitalization, IP.location, IP.partOf }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 8
            }
          ],
          "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" : 9
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Race"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Race\":\n  SDE.\"SDE Race\""
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 10
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Medication Administration"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Medication Administration\":\n  \"MedicationAdministrations\" MedAdministrations\n    where exists ( \"Initial Population\" InitialPopulation\n        where MedAdministrations.effective.toInterval ( ) overlaps InitialPopulation.\"hospitalizationWithObservation\" ( )\n    )\n    return { MedAdministrations.id, MedAdministrations.meta, MedAdministrations.instantiates, MedAdministrations.partOf, MedAdministrations.status, MedAdministrations.statusReason, MedAdministrations.category, MedAdministrations.medication, MedAdministrations.subject, MedAdministrations.context, MedAdministrations.supportingInformation, MedAdministrations.effective, MedAdministrations.performer, MedAdministrations.reasonCode, MedAdministrations.reasonReference, MedAdministrations.request, MedAdministrations.device, MedAdministrations.note, MedAdministrations.dosage }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 11
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "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" : 12
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Sex"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Sex\":\n  SDE.\"SDE Sex\""
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 13
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Initial Population Encounters"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Initial Population Encounters\":\n  \"Initial Population\" IP\n    return { IP.id, IP.meta, IP.identifier, IP.status, IP.statusHistory, IP.class, IP.classHistory, IP.type, IP.serviceType, IP.priority, IP.subject, IP.period, IP.length, IP.reasonCode, IP.reasonReference, IP.diagnosis, IP.account, IP.hospitalization, IP.location, IP.partOf }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 14
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Blood Glucose Observation"
            },
            {
              "url" : "statement",
              "valueString" : "//Supplemental Data Elements\n\n\ndefine \"SDE Blood Glucose Observation\":\n  ( [\"LaboratoryResultObservation\": \"Blood Glucose Laboratory and Point of Care Tests\"] GlucoseTest\n      where exists ( \"Initial Population\" InitialPopulation\n          where start of GlucoseTest.effective.toInterval ( ) during day of InitialPopulation.period\n            or GlucoseTest.issued during day of InitialPopulation.period\n      )\n      return { GlucoseTest.id, GlucoseTest.extension, GlucoseTest.text, GlucoseTest.referenceRange, GlucoseTest.component, GlucoseTest.basedOn, GlucoseTest.partOf, GlucoseTest.category, GlucoseTest.status, GlucoseTest.subject, GlucoseTest.focus, GlucoseTest.encounter, GlucoseTest.effective, GlucoseTest.issued, GlucoseTest.performer, GlucoseTest.value, GlucoseTest.dataAbsentReason, GlucoseTest.interpretation, GlucoseTest.note, GlucoseTest.bodySite, GlucoseTest.method, GlucoseTest.specimen, GlucoseTest.device, GlucoseTest.hasMember, GlucoseTest.derivedFrom }\n  )"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 15
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Condition"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Condition\":\n  [\"ConditionProblemsHealthConcerns\"] Diagnosis\n    where exists ( \"Initial Population\" IP\n        where Diagnosis.prevalenceInterval ( ) overlaps day of IP.period\n    )\n    return { Diagnosis.id, Diagnosis.meta, Diagnosis.clinicalStatus, Diagnosis.verificationStatus, Diagnosis.category, Diagnosis.severity, Diagnosis.code, Diagnosis.bodySite, Diagnosis.subject, Diagnosis.encounter.reference.getId ( ), Diagnosis.onset, Diagnosis.stage, Diagnosis.evidence, Diagnosis.note }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 16
            }
          ],
          "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" : 17
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Payer"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Payer\":\n  SDE.\"SDE Payer\""
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 18
            }
          ],
          "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" : 19
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Ethnicity"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Ethnicity\":\n  SDE.\"SDE Ethnicity\""
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 20
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "Get Locations from Initial Population"
            },
            {
              "url" : "statement",
              "valueString" : "define \"Get Locations from Initial Population\":\n  flatten ( \"Initial Population\" IP\n      let locationElements: IP.location\n      return locationElements LE\n        let locationReference: LE.location\n        return ( locationReference.getLocation ( ) )\n  )"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 21
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Location"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Location\":\n  \"Get Locations from Initial Population\" Locations\n    where exists \"Initial Population\"\n      and Locations is not null\n    return { Locations.id, Locations.meta, Locations.extension, Locations.status, Locations.operationalStatus, Locations.name, Locations.alias, Locations.description, Locations.mode, Locations.type, Locations.telecom, Locations.address, Locations.physicalType, Locations.position, Locations.managingOrganization, Locations.partOf, Locations.hoursOfOperation, Locations.availabilityExceptions, Locations.endpoint }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 22
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Service Request"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Service Request\":\n  [ServiceRequest] ServiceRequests\n    where exists ( \"Initial Population\" InitialPopulation\n        where ServiceRequests.authoredOn during InitialPopulation.period\n    )\n    return { ServiceRequests.id, ServiceRequests.meta, ServiceRequests.instantiatesCanonical, ServiceRequests.instantiatesUri, ServiceRequests.basedOn, ServiceRequests.replaces, ServiceRequests.requisition, ServiceRequests.status, ServiceRequests.intent, ServiceRequests.category, ServiceRequests.priority, ServiceRequests.doNotPerform, ServiceRequests.code, ServiceRequests.orderDetail, ServiceRequests.quantity, ServiceRequests.subject, ServiceRequests.encounter, ServiceRequests.occurrence, ServiceRequests.asNeeded, ServiceRequests.authoredOn, ServiceRequests.requester, ServiceRequests.performerType, ServiceRequests.performer, ServiceRequests.locationCode, ServiceRequests.reasonCode, ServiceRequests.reasonReference, ServiceRequests.insurance, ServiceRequests.bodySite, ServiceRequests.note, ServiceRequests.patientInstruction }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 23
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Minimal Patient"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Minimal Patient\":\n  [Patient] MinPt\n    where exists \"Initial Population\"\n    return { MinPt.id, MinPt.meta, MinPt.extension, MinPt.identifier, MinPt.active, MinPt.name, MinPt.telecom, MinPt.gender, MinPt.birthDate, MinPt.deceased, MinPt.address, MinPt.maritalStatus, MinPt.multipleBirth, MinPt.photo, MinPt.contact, MinPt.communication, MinPt.generalPractitioner, MinPt.managingOrganization, MinPt.link }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 24
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Medication"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Medication\":\n  ( \"MedicationRequests\"\n    union \"MedicationAdministrations\" ) MedReqOrAdmin\n    let medication: GetMedication(MedReqOrAdmin.medication as Reference)\n    where medication is not null\n      and exists ( \"Initial Population\" IP\n          where Coalesce(MedReqOrAdmin.effective.toInterval(), MedReqOrAdmin.authoredOn.toInterval()) overlaps IP.\"hospitalizationWithObservation\" ( )\n      )\n    return { medication.id, medication.meta, medication.code, medication.status, medication.manufacturer, medication.form, medication.amount, medication.ingredient, medication.batch }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 25
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "SDE Chief Complaint"
            },
            {
              "url" : "statement",
              "valueString" : "define \"SDE Chief Complaint\":\n  \"Initial Population\" IP\n    where exists ( IP.diagnosis InitialPopulationDiagnosis\n        where InitialPopulationDiagnosis.use ~ QICoreCommon.\"CC\"\n    )\n    return { IP.id, IP.meta, IP.identifier, IP.status, IP.statusHistory, IP.class, IP.classHistory, IP.type, IP.serviceType, IP.priority, IP.subject, IP.period, IP.length, IP.reasonCode, IP.reasonReference, IP.diagnosis, IP.account, IP.hospitalization, IP.location, IP.partOf }"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 26
            }
          ],
          "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" : 27
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "CQMCommon"
            },
            {
              "url" : "name",
              "valueString" : "getLocation"
            },
            {
              "url" : "statement",
              "valueString" : "/*\n@description: Returns the Location resource specified by the given reference.\n*/\ndefine fluent function getLocation(reference Reference):\n  singleton from (\n    [Location] L where reference.references(L)\n  )"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 28
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "QICoreCommon"
            },
            {
              "url" : "name",
              "valueString" : "references"
            },
            {
              "url" : "statement",
              "valueString" : "/*\n@description: Returns true if the given reference is to the given resource\n@comment: Returns true if the `id` element of the given resource exactly equals the tail of the given reference.\nNOTE: This function assumes resources from the same source server.\n*/\ndefine fluent function references(reference Reference, resource Resource):\n  resource.id = Last(Split(reference.reference, '/'))"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 29
            }
          ],
          "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" : 30
            }
          ],
          "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" : 31
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "CQMCommon"
            },
            {
              "url" : "name",
              "valueString" : "getMedicationCode"
            },
            {
              "url" : "statement",
              "valueString" : "/*\n@description: Returns the medication code for the given MedicationRequest\n*/\ndefine fluent function getMedicationCode(request MedicationRequest):\n  if request.medication is Concept then\n  \t  request.medication as Concept\n  \telse\n  \t  (singleton from ([Medication] M where request.medication.references(M))).code"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 32
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "getMedicationAdministrationCode"
            },
            {
              "url" : "statement",
              "valueString" : "define fluent function getMedicationAdministrationCode(admin MedicationAdministration):\n  if admin.medication is Concept then admin.medication as Concept \n    else ( singleton from ( [Medication] M\n        where admin.medication.references ( M )\n    )\n  ).code"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 33
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "CQMCommon"
            },
            {
              "url" : "name",
              "valueString" : "hospitalizationWithObservation"
            },
            {
              "url" : "statement",
              "valueString" : "/*\n@description: Hospitalization with Observation returns the total interval from the start of any immediately prior emergency department visit through the observation visit to the discharge of the given encounter\n*/\ndefine fluent function hospitalizationWithObservation(TheEncounter Encounter ):\n  TheEncounter Visit\n  \t\tlet ObsVisit: Last([Encounter: \"Observation Services\"] LastObs\n  \t\t\t\twhere LastObs.status = 'finished'\n            and LastObs.period ends 1 hour or less on or before start of Visit.period\n  \t\t\t\tsort by end of period\n  \t\t\t),\n  \t\t\tVisitStart: Coalesce(start of ObsVisit.period, start of Visit.period),\n  \t\t\tEDVisit: Last([Encounter: \"Emergency Department Visit\"] LastED\n  \t\t\t\twhere LastED.status = 'finished'\n            and LastED.period ends 1 hour or less on or before VisitStart\n  \t\t\t\tsort by end of period\n  \t\t\t)\n  \t\treturn Interval[Coalesce(start of EDVisit.period, VisitStart), end of Visit.period]"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 34
            }
          ],
          "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" : 35
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "QICoreCommon"
            },
            {
              "url" : "name",
              "valueString" : "prevalenceInterval"
            },
            {
              "url" : "statement",
              "valueString" : "/*\n@description: Returns an interval representing the normalized prevalence period of a given Condition.\n@comment: Uses the ToInterval and ToAbatementInterval functions to determine the widest potential interval from\nonset to abatement as specified in the given Condition. If the condition is active, or has an abatement date the resulting \ninterval will have a closed ending boundary. Otherwise, the resulting interval will have an open ending boundary.\n*/\ndefine fluent function prevalenceInterval(condition Choice<\"ConditionEncounterDiagnosis\", \"ConditionProblemsHealthConcerns\">):\nif condition.clinicalStatus ~ \"active\"\n  or condition.clinicalStatus ~ \"recurrence\"\n  or condition.clinicalStatus ~ \"relapse\" then\n  Interval[start of condition.onset.toInterval(), end of condition.abatementInterval()]\nelse\n    (end of condition.abatementInterval()) abatementDate\n    return if abatementDate is null then\n      Interval[start of condition.onset.toInterval(), abatementDate)\n    else\n      Interval[start of condition.onset.toInterval(), abatementDate]"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 36
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "QICoreCommon"
            },
            {
              "url" : "name",
              "valueString" : "abatementInterval"
            },
            {
              "url" : "statement",
              "valueString" : "/*\n@description: Returns an interval representing the normalized abatement of a given Condition.\n@comment: If the abatement element of the Condition is represented as a DateTime, the result\nis an interval beginning and ending on that DateTime.\nIf the abatement is represented as a Quantity, the quantity is expected to be a calendar-duration and is interpreted as the age of the patient. The\nresult is an interval from the date the patient turned that age to immediately before one year later.\nIf the abatement is represented as a Quantity Interval, the quantities are expected to be calendar-durations and are interpreted as an age range during\nwhich the abatement occurred. The result is an interval from the date the patient turned the starting age of the quantity interval, and ending immediately\nbefore one year later than the date the patient turned the ending age of the quantity interval.\n*/\ndefine fluent function abatementInterval(condition Choice<\"ConditionEncounterDiagnosis\", \"ConditionProblemsHealthConcerns\">):\n\tif condition.abatement is DateTime then\n\t  Interval[condition.abatement as DateTime, condition.abatement as DateTime]\n\telse if condition.abatement is Quantity then\n\t\tInterval[Patient.birthDate + (condition.abatement as Quantity),\n\t\t\tPatient.birthDate + (condition.abatement as Quantity) + 1 year)\n\telse if condition.abatement is Interval<Quantity> then\n\t  Interval[Patient.birthDate + (condition.abatement.low as Quantity),\n\t\t  Patient.birthDate + (condition.abatement.high as Quantity) + 1 year)\n\telse if condition.abatement is Interval<DateTime> then\n\t  Interval[condition.abatement.low, condition.abatement.high)\n\telse null as Interval<DateTime>"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 37
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "QICoreCommon"
            },
            {
              "url" : "name",
              "valueString" : "getId"
            },
            {
              "url" : "statement",
              "valueString" : "/*\n@description: Returns the tail of the given uri (i.e. everything after the last slash in the URI).\n@comment: This function can be used to determine the logical id of a given resource. It can be used in\na single-server environment to trace references. However, this function does not attempt to resolve\nor distinguish the base of the given url, and so cannot be used safely in multi-server environments.\n*/\ndefine fluent function getId(uri String):\n  Last(Split(uri, '/'))"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 38
            }
          ],
          "url" : "http://hl7.org/fhir/StructureDefinition/cqf-logicDefinition"
        },
        {
          "extension" : [
            {
              "url" : "libraryName",
              "valueString" : "NHSNGlycemicControlHypoglycemiaInitialPopulation"
            },
            {
              "url" : "name",
              "valueString" : "GetMedication"
            },
            {
              "url" : "statement",
              "valueString" : "define function \"GetMedication\"(reference Reference):\n  singleton from ( [Medication] Medication\n      where reference.references ( Medication )\n  )"
            },
            {
              "url" : "displaySequence",
              "valueInteger" : 39
            }
          ],
          "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" : 40
            }
          ],
          "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 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" : "Library CQMCommon",
          "resource" : "https://madie.cms.gov/Library/CQMCommon|4.1.000"
        },
        {
          "type" : "depends-on",
          "display" : "Library SDE",
          "resource" : "https://madie.cms.gov/Library/SupplementalDataElements|5.1.000"
        },
        {
          "type" : "depends-on",
          "display" : "Code system ActCode",
          "resource" : "http://terminology.hl7.org/CodeSystem/v3-ActCode"
        },
        {
          "type" : "depends-on",
          "display" : "Code system SNOMEDCT",
          "resource" : "http://snomed.info/sct"
        },
        {
          "type" : "depends-on",
          "display" : "Code system ConditionClinicalStatusCodes",
          "resource" : "http://terminology.hl7.org/CodeSystem/condition-clinical"
        },
        {
          "type" : "depends-on",
          "display" : "Code system Diagnosis Role",
          "resource" : "http://terminology.hl7.org/CodeSystem/diagnosis-role"
        },
        {
          "type" : "depends-on",
          "display" : "Value set Encounter Inpatient",
          "resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307"
        },
        {
          "type" : "depends-on",
          "display" : "Value set Inpatient, Emergency, and Observation Locations",
          "resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1046.265"
        },
        {
          "type" : "depends-on",
          "display" : "Value set Diabetes Medications",
          "resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1190.58"
        },
        {
          "type" : "depends-on",
          "display" : "Value set Observation Services",
          "resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143"
        },
        {
          "type" : "depends-on",
          "display" : "Value set Emergency Department Visit",
          "resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292"
        },
        {
          "type" : "depends-on",
          "display" : "Value set Blood Glucose Laboratory and Point of Care Tests",
          "resource" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1190.38"
        },
        {
          "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" : "Initial Population",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Coverage",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Medication Request",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Encounter Locations",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Race",
          "use" : "out",
          "min" : 0,
          "max" : "1",
          "type" : "Resource"
        },
        {
          "name" : "SDE Medication Administration",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Sex",
          "use" : "out",
          "min" : 0,
          "max" : "1",
          "type" : "Coding"
        },
        {
          "name" : "SDE Initial Population Encounters",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Blood Glucose Observation",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Condition",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Payer",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Ethnicity",
          "use" : "out",
          "min" : 0,
          "max" : "1",
          "type" : "Resource"
        },
        {
          "name" : "SDE Location",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Service Request",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Minimal Patient",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Medication",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        },
        {
          "name" : "SDE Chief Complaint",
          "use" : "out",
          "min" : 0,
          "max" : "*",
          "type" : "Resource"
        }
      ],
      "dataRequirement" : [
        {
          "type" : "Encounter",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
          ],
          "mustSupport" : [
            "type",
            "status",
            "status.value",
            "period",
            "location",
            "id",
            "id.value",
            "meta",
            "identifier",
            "statusHistory",
            "class",
            "classHistory",
            "serviceType",
            "priority",
            "subject",
            "length",
            "reasonCode",
            "reasonReference",
            "diagnosis",
            "account",
            "hospitalization",
            "partOf"
          ],
          "codeFilter" : [
            {
              "path" : "type",
              "valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1111.143"
            }
          ]
        },
        {
          "type" : "Encounter",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
          ],
          "mustSupport" : [
            "type",
            "status",
            "status.value",
            "period",
            "location",
            "id",
            "id.value",
            "meta",
            "identifier",
            "statusHistory",
            "class",
            "classHistory",
            "serviceType",
            "priority",
            "subject",
            "length",
            "reasonCode",
            "reasonReference",
            "diagnosis",
            "account",
            "hospitalization",
            "partOf"
          ],
          "codeFilter" : [
            {
              "path" : "type",
              "valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.117.1.7.1.292"
            }
          ]
        },
        {
          "type" : "Encounter",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-encounter"
          ],
          "mustSupport" : [
            "type",
            "period",
            "class",
            "status",
            "status.value",
            "location",
            "id",
            "id.value",
            "meta",
            "identifier",
            "statusHistory",
            "classHistory",
            "serviceType",
            "priority",
            "subject",
            "length",
            "reasonCode",
            "reasonReference",
            "diagnosis",
            "account",
            "hospitalization",
            "partOf"
          ],
          "codeFilter" : [
            {
              "path" : "type",
              "valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.666.5.307"
            }
          ]
        },
        {
          "type" : "Resource",
          "profile" : [
            🔗 "http://hl7.org/fhir/StructureDefinition/Resource"
          ],
          "mustSupport" : [
            "id",
            "id.value"
          ]
        },
        {
          "type" : "Location",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-location"
          ],
          "mustSupport" : [
            "id",
            "id.value",
            "meta",
            "extension",
            "status",
            "status.value",
            "operationalStatus",
            "name",
            "name.value",
            "alias",
            "description",
            "description.value",
            "mode",
            "mode.value",
            "type",
            "telecom",
            "address",
            "physicalType",
            "position",
            "managingOrganization",
            "partOf",
            "hoursOfOperation",
            "availabilityExceptions",
            "availabilityExceptions.value",
            "endpoint"
          ]
        },
        {
          "type" : "MedicationRequest",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-medicationrequest"
          ],
          "mustSupport" : [
            "medication",
            "authoredOn",
            "authoredOn.value",
            "id",
            "id.value",
            "meta",
            "status",
            "status.value",
            "statusReason",
            "intent",
            "intent.value",
            "category",
            "priority",
            "priority.value",
            "doNotPerform",
            "doNotPerform.value",
            "reported",
            "subject",
            "encounter",
            "requester",
            "recorder",
            "reasonCode",
            "reasonReference",
            "instantiatesCanonical",
            "instantiatesUri",
            "courseOfTherapyType",
            "dosageInstruction"
          ]
        },
        {
          "type" : "MedicationAdministration",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-medicationadministration"
          ],
          "mustSupport" : [
            "medication",
            "effective",
            "id",
            "id.value",
            "meta",
            "instantiates",
            "partOf",
            "status",
            "status.value",
            "statusReason",
            "category",
            "subject",
            "context",
            "supportingInformation",
            "performer",
            "reasonCode",
            "reasonReference",
            "request",
            "device",
            "note",
            "dosage"
          ]
        },
        {
          "type" : "Medication",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-medication"
          ],
          "mustSupport" : [
            "code"
          ]
        },
        {
          "type" : "Coverage",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-coverage"
          ],
          "mustSupport" : [
            "period",
            "id",
            "id.value",
            "meta",
            "status",
            "status.value",
            "type",
            "policyHolder",
            "subscriber",
            "subscriberId",
            "subscriberId.value",
            "beneficiary",
            "dependent",
            "dependent.value",
            "relationship",
            "payor",
            "class",
            "order",
            "order.value",
            "network",
            "network.value",
            "subrogation",
            "subrogation.value",
            "contract"
          ]
        },
        {
          "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"
            }
          ]
        },
        {
          "type" : "Patient",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-patient"
          ],
          "mustSupport" : [
            "url",
            "extension",
            "birthDate",
            "birthDate.value",
            "id",
            "id.value",
            "meta",
            "identifier",
            "active",
            "active.value",
            "name",
            "telecom",
            "gender",
            "gender.value",
            "deceased",
            "address",
            "maritalStatus",
            "multipleBirth",
            "photo",
            "contact",
            "communication",
            "generalPractitioner",
            "managingOrganization",
            "link"
          ]
        },
        {
          "type" : "Observation",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-observation-lab"
          ],
          "mustSupport" : [
            "code",
            "effective",
            "issued",
            "issued.value",
            "id",
            "id.value",
            "extension",
            "text",
            "referenceRange",
            "component",
            "basedOn",
            "partOf",
            "category",
            "status",
            "status.value",
            "subject",
            "focus",
            "encounter",
            "performer",
            "value",
            "dataAbsentReason",
            "interpretation",
            "note",
            "bodySite",
            "method",
            "specimen",
            "device",
            "hasMember",
            "derivedFrom"
          ],
          "codeFilter" : [
            {
              "path" : "code",
              "valueSet" : "http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113762.1.4.1190.38"
            }
          ]
        },
        {
          "type" : "Condition",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-condition-problems-health-concerns"
          ],
          "mustSupport" : [
            "id",
            "id.value",
            "meta",
            "clinicalStatus",
            "verificationStatus",
            "category",
            "severity",
            "code",
            "bodySite",
            "subject",
            "encounter",
            "encounter.reference",
            "encounter.reference.value",
            "onset",
            "stage",
            "evidence",
            "note"
          ]
        },
        {
          "type" : "ServiceRequest",
          "profile" : [
            🔗 "http://hl7.org/fhir/us/qicore/StructureDefinition/qicore-servicerequest"
          ],
          "mustSupport" : [
            "authoredOn",
            "authoredOn.value",
            "id",
            "id.value",
            "meta",
            "instantiatesCanonical",
            "instantiatesUri",
            "basedOn",
            "replaces",
            "requisition",
            "status",
            "status.value",
            "intent",
            "intent.value",
            "category",
            "priority",
            "priority.value",
            "doNotPerform",
            "doNotPerform.value",
            "code",
            "orderDetail",
            "quantity",
            "subject",
            "encounter",
            "occurrence",
            "asNeeded",
            "requester",
            "performerType",
            "performer",
            "locationCode",
            "reasonCode",
            "reasonReference",
            "insurance",
            "bodySite",
            "note",
            "patientInstruction",
            "patientInstruction.value"
          ]
        }
      ]
    }
  ],
  "extension" : [
    {
      "id" : "supplementalDataGuidance",
      "extension" : [
        {
          "url" : "guidance",
          "valueString" : "<p>Supplemental Data</p>"
        },
        {
          "url" : "usage",
          "valueCodeableConcept" : {
            "coding" : [
              {
                "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
                "code" : "supplemental-data",
                "display" : "Supplemental Data"
              }
            ],
            "text" : "Supplemental Data Guidance"
          }
        }
      ],
      "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-supplementalDataGuidance"
    },
    {
      "extension" : [
        {
          "url" : "term",
          "valueString" : "Blood glucose"
        },
        {
          "url" : "definition",
          "valueMarkdown" : "Blood-glucose data refers to data from random, periprandial, or fasting tests; from capillary, serum, plasma, interstitial fluid, or whole-blood sources; using central laboratory device (CLD) or point-of-care (POC) testing. Data from continuous glucose monitoring (CGM) systems can only be captured if they are integrated into the EHR and exposed in the corresponding FHIR resources. Post-glucose administration tests are excluded. Events are based on the day/time the laboratory test was collected (drawn). If day/time collected is not available, the day/time the lab was ordered is used.\n"
        }
      ],
      "url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
    },
    {
      "extension" : [
        {
          "url" : "term",
          "valueString" : "Emergency department (ED)/Observation (Obs) encounter"
        },
        {
          "url" : "definition",
          "valueMarkdown" : "Any patient visit to an ED or observation location. One (1) patient visit equals one (1) encounter. ED/Observation encounters are considered outpatient locations.\n"
        }
      ],
      "url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
    },
    {
      "extension" : [
        {
          "url" : "term",
          "valueString" : "Hypoglycemic medication"
        },
        {
          "url" : "definition",
          "valueMarkdown" : "All currently and previously commercially available oral or injectable hypoglycemic medications in the United States.\n"
        }
      ],
      "url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
    },
    {
      "extension" : [
        {
          "url" : "term",
          "valueString" : "Inpatient encounter"
        },
        {
          "url" : "definition",
          "valueMarkdown" : "Includes all encounters in inpatient locations.\n"
        }
      ],
      "url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
    },
    {
      "extension" : [
        {
          "url" : "term",
          "valueString" : "Mild hypoglycemia event"
        },
        {
          "url" : "definition",
          "valueMarkdown" : "Blood glucose 54.0 mg/dL to 69.9 mg/dL as identified on CLD or prescription POC device with no subsequent repeat test for blood glucose with a result \\> 80 mg/dL within 5 minutes of the start of the initial low blood glucose test.\n"
        }
      ],
      "url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
    },
    {
      "extension" : [
        {
          "url" : "term",
          "valueString" : "Moderate hypoglycemia event"
        },
        {
          "url" : "definition",
          "valueMarkdown" : "Blood glucose 40.0 mg/dL to 53.9 mg/dL as identified on CLD or prescription POC device with no subsequent repeat test for blood glucose with a result \\> 80 mg/dL within 5 minutes of the start of the initial low blood glucose test.\n"
        }
      ],
      "url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
    },
    {
      "extension" : [
        {
          "url" : "term",
          "valueString" : "Severe hypoglycemia event"
        },
        {
          "url" : "definition",
          "valueMarkdown" : "Blood glucose \\< 40.0 mg/dL as identified on CLD or prescription POC device with no subsequent repeat test for blood glucose with a result \\> 80 mg/dL within 5 minutes of the start of the initial low blood glucose test.\n"
        }
      ],
      "url" : "http://hl7.org/fhir/StructureDefinition/cqf-definitionTerm"
    },
    {
      "url" : "http://hl7.org/fhir/uv/crmi/StructureDefinition/crmi-effectiveDataRequirements",
      "valueReference" : {
        "reference" : "#effective-data-requirements"
      }
    }
  ],
  "url" : "https://madie.cms.gov/Measure/NHSNGlycemicControlHypoglycemiaInitialPopulation",
  "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" : "NHSNHypoglycemia"
    },
    {
      "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:0d555fb6-f654-418c-a2b3-2dd0c3f0e7b4"
    },
    {
      "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:dc9459ed-48ca-45f3-923e-3352d9547461"
    }
  ],
  "version" : "0.0.003",
  "name" : "NHSNGlycemicControlHypoglycemiaInitialPopulation",
  "title" : "NHSN Glycemic Control Hypoglycemia Initial Population\n",
  "status" : "active",
  "experimental" : false,
  "date" : "2025-08-21T20:27:09+00:00",
  "publisher" : "Centers for Disease Control and Prevention (CDC)",
  "contact" : [
    {
      "telecom" : [
        {
          "system" : "url",
          "value" : "www.cdc.gov/hiv/"
        }
      ]
    }
  ],
  "description" : "All inpatient encounters (including ED/Observation visits that end within 1 hour of the start of the inpatient encounter) for patients of all ages where at least one diabetes medication was ordered or administered during the encounter that is during the measurement period.\n",
  "useContext" : [
    {
      "code" : {
        "system" : "http://terminology.hl7.org/CodeSystem/usage-context-type",
        "code" : "venue",
        "display" : "Venue"
      },
      "valueCodeableConcept" : {
        "coding" : [
          {
            "system" : "http://hl7.org/fhir/us/cqfmeasures/CodeSystem/intended-venue-codes",
            "code" : "eh",
            "display" : "EH"
          }
        ]
      }
    }
  ],
  "purpose" : "The primary objective of the NHSN Glycemic Control module is to measure and benchmark medication-related hypoglycemia and hyperglycemia events within a facility. NHSN uses line-level data on medications and blood glucose reported by facilities to provide analytic reports to inform quality-improvement efforts for glycemic control and track patient safety events. As NHSN collects additional data, an additional objective will be to allow inter-facility benchmarking and evaluate national-level trends of medication-related hypoglycemia over time.\n",
  "usage" : "All participating inpatient facilities reporting data to the NHSN Glycemic Control module must be able to report data electronically in adherence to HL7 FHIR US Core FHIR R4.0.1 data standards and specifications and NHSN instructions for reporting dQMs, including the HL7 NHSN dQM Reporting Implementation Guide (https://build.fhir.org/ig/HL7/nhsn-dqm/).\n",
  "copyright" : "Limited proprietary coding is contained in the Measure specifications for user convenience. Users of proprietary code sets should obtain all necessary licenses from the owners of the code sets.\n",
  "effectivePeriod" : {
    "start" : "2026-01-01",
    "end" : "2026-12-31"
  },
  "author" : [
    {
      "name" : "Lantana Consulting Group",
      "telecom" : [
        {
          "system" : "url",
          "value" : "https://www.lantanagroup.com/"
        }
      ]
    }
  ],
  "relatedArtifact" : [
    {
      "type" : "citation",
      "citation" : "American Diabetes Association. Economic costs of diabetes in the U.S. in 2012. Diabetes Care 2013;36:1033--46.\n"
    },
    {
      "type" : "citation",
      "citation" : "Bates, D. W., Levine, D. M., Salmasian, H., et al. (2023). The safety of inpatient health care. New England Journal of Medicine, 388(12), 142--153.\n"
    },
    {
      "type" : "citation",
      "citation" : "Classen, D. C., Resar, R., Griffin, F., et al. (2011). 'Global trigger tool' shows that adverse events in hospitals may be ten times greater than previously measured. Health Affairs, 30(4), 581--589.\n"
    },
    {
      "type" : "citation",
      "citation" : "Cook, C. B., Kongable, G. L., Potter, D. J., et al. (2009). Inpatient glucose control: A glycemic survey of 126 U.S. hospitals. Journal of Hospital Medicine, 4(E7), E7--E14.\n"
    },
    {
      "type" : "citation",
      "citation" : "Curkendall, S. M., Natoli, J. L., Alexander, C. M., et al. (2009). Economic and clinical impact of inpatient diabetic hypoglycemia. Endocrine Practice, 15(3), 302--312.\n"
    },
    {
      "type" : "citation",
      "citation" : "Egi, M., Bellomo, R., Stachowski, E., et al. (2010). Hypoglycemia and outcome in critically ill patients. Mayo Clinic Proceedings, 85(3), 217--224.\n"
    },
    {
      "type" : "citation",
      "citation" : "Finfer, S., Liu, B., Chittock, D. R., et al. (2012). Hypoglycemia and risk of death in critically ill patients. New England Journal of Medicine, 367, 1108--1118.\n"
    },
    {
      "type" : "citation",
      "citation" : "Gates, P. J., Meyerson, S. A., Baysari, M. T., et al. (2018). Preventable adverse drug events among inpatients: A systematic review. Pediatrics, 142, e20180805.\n"
    },
    {
      "type" : "citation",
      "citation" : "Hulkower RD, Pollack RM, Zonszein J. Understanding hypoglycemia in hospitalized patients. Diabetes Manag (Lond) 2014;4:165-76.\n"
    },
    {
      "type" : "citation",
      "citation" : "Maynard, G., et al. (2014). How sweet is it? The use of benchmarking to optimize inpatient glycemic control. Diabetes Spectrum, 27, 212--217.\n"
    },
    {
      "type" : "citation",
      "citation" : "Moghissi ES, Korytkowski MT, DiNardo M. American Association of Clinical Endocrinologists and American Diabetes Association consensus statement on inpatient glycemic control. Endocr Pract 2009;15:353-69.\n"
    },
    {
      "type" : "citation",
      "citation" : "Society of Hospital Medicine. Glycemic Control for Hospitalists. Optimizing Care, Preventing Hypoglycemia. Available at: https://www.hospitalmedicine.org/clinical-topics/glycemic-control.\n"
    },
    {
      "type" : "citation",
      "citation" : "Spector, W. D., Limcangco, R., Furukawa, M. F., Encinosa, W. E. (2017). The marginal costs of adverse drug events associated with exposures to anticoagulants and hypoglycemic agents during hospitalization. Medical Care, 55(8), 856--863.\n"
    },
    {
      "type" : "citation",
      "citation" : "Turchin, A., Matheny, M. E., Shubina, M., et al. (2009). Hypoglycemia and clinical outcomes in patients with diabetes hospitalized in the general ward. Diabetes Care, 32(7), 1153--1157.\n"
    },
    {
      "type" : "citation",
      "citation" : "Umpierrez, G. E., Isaacs, S. D., Bazargan, N., et al. (2002). Hyperglycemia: An independent marker of in-hospital mortality in patients with undiagnosed diabetes. Journal of Clinical Endocrinology \\& Metabolism, 87(3), 978--982.\n"
    },
    {
      "type" : "citation",
      "citation" : "Wexler, D. J., et al. (2007). Prevalence of hyper- and hypoglycemia among inpatients with diabetes: A national survey of 44 U.S. hospitals. Diabetes Care, 30(2), 367--369.\n"
    }
  ],
  "library" : [
    🔗 "https://madie.cms.gov/Library/NHSNGlycemicControlHypoglycemiaInitialPopulation"
  ],
  "disclaimer" : "Disclaimer This performance 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 MEASURES AND SPECIFICATIONS ARE PROVIDED \"AS IS\" WITHOUT WARRANTY OF ANY KIND.\n\nThis measure and specifications are subject to further revisions.\n",
  "rationale" : "The NHSN Glycemic Control module supports an electronic health record (EHR)- and vendor-neutral standard for reporting patient-level, linked medication and blood glucose data for inpatients. These data support calculation of inpatient medication-related hypoglycemia events by the NHSN application, which are then returned as reports to the facility.\n",
  "clinicalRecommendationStatement" : "Inpatient hypoglycemia can be severe and life-threatening and is associated with longer hospital stays and increased medical costs (Wexler et al., 2007; Curkendall et al., 2009; Cook et al., 2009; Turchin et al., 2009; Egi et al., 2010). The prevalence of inpatient hypoglycemia varies with patient, hospital unit, timing of episodes, and glycemic threshold. Severe hypoglycemia (\\<40 mg/dL) occurs in 2%--5% of hospitalized patients with diabetes mellitus (DM), while hypoglycemia \\<70 mg/dL has been reported in up to 10% of all patients in the intensive care unit (Finfer et al., 2012). Patients with DM comprise more than 25% of all U.S. inpatient stays and medication-related hypoglycemia events are common causes of adverse drug events (ADEs) that occur in inpatient settings (Bates et al., 2023; Spector et al., 2017). Rates of severe hypoglycemia vary across hospitals, suggesting opportunities for improvement in glycemic-control quality of care (Hulkower et al., 2014; ADA, 2013; Cook et al., 2009).\n\nInpatient hyperglycemia can increase morbidity, prolong hospital stays, and increase the risk of mortality (Maynard et al., 2014; SHM, n.d.; Umpierrez et al., 2002; Kyi et al., 2019; Pratiwi et al., 2021). The prevalence of inpatient hyperglycemia varies depending upon glycemic threshold and setting, but blood glucose \\>140 mg/dL likely occurs in approximately one-eighth to one-quarter of hospitalized patients (Pratiwi et al., 2021; Seisa et al., 2022; Barmanray et al., 2024). Tracking patient blood-glucose levels and implementing appropriate interventions may reduce complications associated with both hyperglycemia and hypoglycemia (ADA, 2013; Cook et al., 2009; Korytkowski et al., 2022; Moghissi et al., 2009).\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" : "cohort",
                "display" : "Cohort"
              }
            ]
          }
        },
        {
          "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"
              }
            ]
          }
        }
      ],
      "population" : [
        {
          "id" : "InitialPopulation_1",
          "code" : {
            "coding" : [
              {
                "system" : "http://terminology.hl7.org/CodeSystem/measure-population",
                "code" : "initial-population",
                "display" : "Initial Population"
              }
            ]
          },
          "description" : "All inpatient encounters, as well as ED and OBS encounters that end within 1 hour of the start of the inpatient encounter, for patients of all ages where at least one diabetes medication was ordered or administered during the encounter that is during the measurement period.\n",
          "criteria" : {
            "language" : "text/cql-identifier",
            "expression" : "Initial Population"
          }
        }
      ]
    }
  ],
  "supplementalData" : [
    {
      "id" : "sde-encounter-locations",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Encounter Locations\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Encounter Locations"
      }
    },
    {
      "id" : "sde-location",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Location\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Location"
      }
    },
    {
      "id" : "sde-medication",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Medication\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Medication"
      }
    },
    {
      "id" : "sde-blood-glucose-observation",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Blood Glucose Observation\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Blood Glucose Observation"
      }
    },
    {
      "id" : "sde-chief-complaint",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Chief Complaint\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Chief Complaint"
      }
    },
    {
      "id" : "sde-condition",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Condition\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Condition"
      }
    },
    {
      "id" : "sde-coverage",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Coverage\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Coverage"
      }
    },
    {
      "id" : "sde-initial-population-encounters",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Initial Population Encounters\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Initial Population Encounters"
      }
    },
    {
      "id" : "sde-medication-administration",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Medication Administration\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Medication Administration"
      }
    },
    {
      "id" : "sde-medication-request",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Medication Request\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Medication Request"
      }
    },
    {
      "id" : "sde-minimal-patient",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Minimal Patient\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Minimal Patient"
      }
    },
    {
      "id" : "sde-service-request",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "usage" : [
        {
          "coding" : [
            {
              "system" : "http://terminology.hl7.org/CodeSystem/measure-data-usage",
              "code" : "supplemental-data"
            }
          ]
        }
      ],
      "description" : "SDE Service Request\n",
      "criteria" : {
        "language" : "text/cql-identifier",
        "expression" : "SDE Service Request"
      }
    },
    {
      "id" : "sde-ethnicity",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "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",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "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",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "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",
      "extension" : [
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "individual"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "subject-list"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "summary"
        },
        {
          "url" : "http://hl7.org/fhir/us/cqfmeasures/StructureDefinition/cqfm-includeInReportType",
          "valueCode" : "data-collection"
        }
      ],
      "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"
      }
    }
  ]
}