CMS Draft FHIR Measures
2024.1.0 - CI Build

CMS Draft FHIR Measures, published by cqframework. This guide is not an authorized publication; it is the continuous build for version 2024.1.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-cms-2024/ and changes regularly. See the Directory of published versions

## Library: DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR

Official URL: https://madie.cms.gov/Library/DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR | Version: 0.1.002
Active as of 2024-05-15 | Computable Name: DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR
Other Identifiers: https://madie.cms.gov/login#DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR (use: official, )

DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR

Metadata
Title | DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR
Version | 0.1.002
Identifier | DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR
Topic | FHIR
Topic | CQL
Description | DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR
Type | logic-library from http://terminology.hl7.org/CodeSystem/library-type
Dependency | Description: Library FHIRHelpers Resource: FHIRHelpersversion: null4.4.000) Canonical URL: `https://madie.cms.gov/Library/FHIRHelpers|4.4.000`
Dependency | Description: Library QICoreCommon Resource: QICoreCommonversion: null2.1.000) Canonical URL: `https://madie.cms.gov/Library/QICoreCommon|2.1.000`
Dependency | Description: Library SDE Resource: SupplementalDataElementsversion: null3.5.000) Canonical URL: `https://madie.cms.gov/Library/SupplementalDataElements|3.5.000`
Dependency | Description: Library Status Resource: Statusversion: null1.8.000) Canonical URL: `https://madie.cms.gov/Library/Status|1.8.000`
Dependency | Description: Library CMD Resource: CumulativeMedicationDurationversion: null4.1.000) Canonical URL: `https://madie.cms.gov/Library/CumulativeMedicationDuration|4.1.000`
Dependency | Description: Library AdultOutpatientEncounters Resource: AdultOutpatientEncountersversion: null4.11.000) Canonical URL: `https://madie.cms.gov/Library/AdultOutpatientEncounters|4.11.000`
Dependency | Description: Library AIFrailLTCF Resource: AdvancedIllnessandFrailtyversion: null1.16.000) Canonical URL: `https://madie.cms.gov/Library/AdvancedIllnessandFrailty|1.16.000`
Dependency | Description: Library Hospice Resource: Hospiceversion: null6.12.000) Canonical URL: `https://madie.cms.gov/Library/Hospice|6.12.000`
Dependency | Description: Library PalliativeCare Resource: PalliativeCareversion: null1.11.000) Canonical URL: `https://madie.cms.gov/Library/PalliativeCare|1.11.000`
Dependency | Description: Code System LOINC Resource: Logical Observation Identifiers, Names and Codes (LOINC) Canonical URL: `http://loinc.org`
Dependency | Description: Value Set Diabetes Resource: Diabetes Canonical URL: `http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.103.12.1001`
Dependency | Description: Value Set HbA1c Laboratory Test Resource: HbA1c Laboratory Test Canonical URL: `http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.198.12.1013`
Data Requirement | Type: Condition Profile(s): QICoreCondition Code Filter(s): Path: code ValueSet: Diabetes
Data Requirement | Type: Observation Profile(s): QICoreObservation Code Filter(s): Path: code ValueSet: HbA1c Laboratory Test
Data Requirement | Type: Observation Profile(s): QICoreObservation Code Filter(s): Path: code Code(s): LOINC: 97506-0 (Glucose management indicator)
Parameters
Name | Use | Card. | Type | Documentation
Measurement Period | In | 0..1 | Period |
Patient | Out | 0..1 | Resource |
SDE Ethnicity | Out | 0..1 | Resource |
SDE Payer | Out | 0..* | Resource |
SDE Race | Out | 0..1 | Resource |
SDE Sex | Out | 0..1 | Coding |
Initial Population | Out | 0..1 | boolean |
Denominator | Out | 0..1 | boolean |
Denominator Exclusions | Out | 0..1 | boolean |
Glycemic Status Assessment | Out | 0..* | Resource |
Most Recent Glycemic Status Date | Out | 0..1 | date |
Lowest Glycemic Status Assessment Reading on Most Recent Day | Out | 0..1 | Resource |
Has Most Recent Glycemic Status Assessment Without Result | Out | 0..1 | boolean |
Has Most Recent Elevated Glycemic Status Assessment | Out | 0..1 | boolean |
Has No Record Of Glycemic Status Assessment | Out | 0..1 | boolean |
Numerator | Out | 0..1 | boolean |
Library Content
CQL Content |
    library DiabetesGlycemicStatusAssessmentGreaterThan9PercentFHIR version '0.1.002'

    using QICore version '4.1.1'

    include FHIRHelpers version '4.4.000' called FHIRHelpers
    include QICoreCommon version '2.1.000' called QICoreCommon
    include SupplementalDataElements version '3.5.000' called SDE
    include Status version '1.8.000' called Status
    include CumulativeMedicationDuration version '4.1.000' called CMD
    include AdultOutpatientEncounters version '4.11.000' called AdultOutpatientEncounters
    include AdvancedIllnessandFrailty version '1.16.000' called AIFrailLTCF
    include Hospice version '6.12.000' called Hospice
    include PalliativeCare version '1.11.000' called PalliativeCare

    codesystem "LOINC": 'http://loinc.org'

    valueset "Diabetes": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.103.12.1001'
    valueset "HbA1c Laboratory Test": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.198.12.1013'

    code "Glucose management indicator": '97506-0' from "LOINC" display 'Glucose management indicator'

    parameter "Measurement Period" Interval<DateTime>
      default Interval[@2025-01-01T00:00:00.000Z, @2025-12-31T23:59:59.999Z]

    context Patient

    define "SDE Ethnicity":
      SDE."SDE Ethnicity"

    define "SDE Payer":
      SDE."SDE Payer"

    define "SDE Race":
      SDE."SDE Race"

    define "SDE Sex":
      SDE."SDE Sex"

    define "Initial Population":
      AgeInYearsAt(date from
        end of "Measurement Period"
      ) in Interval[18, 75]
        and exists AdultOutpatientEncounters."Qualifying Encounters"
        and exists ( [Condition: "Diabetes"] Diabetes
            where Diabetes.prevalenceInterval ( ) overlaps day of "Measurement Period"
        )

    define "Denominator":
      "Initial Population"

    define "Denominator Exclusions":
      Hospice."Has Hospice Services"
        or AIFrailLTCF."Is Age 66 or Older Living Long Term in a Nursing Home"
        or AIFrailLTCF."Is Age 66 or Older with Advanced Illness and Frailty"
        or PalliativeCare."Has Palliative Care in the Measurement Period"

    define "Numerator":
      "Has Most Recent Glycemic Status Assessment Without Result"
        or "Has Most Recent Elevated Glycemic Status Assessment"
        or "Has No Record Of Glycemic Status Assessment"

    define "Glycemic Status Assessment":
      ( ( [Observation: "HbA1c Laboratory Test"]
          union [Observation: "Glucose management indicator"]
      ).isLaboratoryTestPerformed ( ) ) GlycemicStatus
        where GlycemicStatus.effective.latest ( ) during day of "Measurement Period"

    define "Lowest Glycemic Status Assessment Reading on Most Recent Day":
      First("Glycemic Status Assessment" QualifyingGlycemicStatus
          where QualifyingGlycemicStatus.effective.latest() same day as "Most Recent Glycemic Status Date"
          return {
            QualifyingGlycemicStatusValue: QualifyingGlycemicStatus.value as Quantity,
            QualifyingGlycemicStatus: QualifyingGlycemicStatus
          }
          sort by QualifyingGlycemicStatusValue
      ).QualifyingGlycemicStatus

    define "Most Recent Glycemic Status Date":
      Last(("Glycemic Status Assessment" QualifyingGlycemicStatus
          return date from QualifyingGlycemicStatus.effective.latest()) QualifyingGlycemicStatus
          sort asc
      )

    define "Has Most Recent Glycemic Status Assessment Without Result":
      "Lowest Glycemic Status Assessment Reading on Most Recent Day" is not null
        and "Lowest Glycemic Status Assessment Reading on Most Recent Day".value is null

    define "Has Most Recent Elevated Glycemic Status Assessment":
      "Lowest Glycemic Status Assessment Reading on Most Recent Day".value > 9 '%'

    define "Has No Record Of Glycemic Status Assessment":
      not exists "Glycemic Status Assessment"
ELM XML Content |
    Encoded data
ELM JSON Content |
    Encoded data
Generated using version 0.5.4-cibuild of the sample-content-ig Liquid templates