Quality Measure Implementation Guide
1.0.0 - STU 1 International flag

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

Library: Adult Outpatient Encounters Common Library (Experimental)

Official URL: http://hl7.org/fhir/uv/cqm/Library/AdultOutpatientEncounters Version: 2.0.000
Standards status: Informative Computable Name: AdultOutpatientEncounters
Other Identifiers: http://example.org/fhir/cqi/ecqm/Library/Identifier#AdultOutpatientEncounters (use: official, ), OID:2.16.840.1.113883.4.642.40.61.28.1

This library is used as an example in the FHIR Quality Measure Implementation Guide

Metadata
Title Adult Outpatient Encounters Common Library
Version 2.0.000
Identifier AdultOutpatientEncounters
Identifier urn:oid:2.16.840.1.113883.4.642.40.61.28.1
Approval Date 2019-08-03
Last Review Date 2019-08-03
Experimental true
Jurisdiction Global (Whole world)
Steward (Publisher) HL7 International / Clinical Quality Information
Description

This library is used as an example in the FHIR Quality Measure Implementation Guide

Type Logic Library
Parameter Name: Measurement Period
Use: In
Min Cardinality: 0
Max Cardinality: 1
Type: Period
Parameter Name: Patient
Use: Out
Min Cardinality: 0
Max Cardinality: 1
Type: Patient
Parameter Name: Qualifying Encounters
Use: Out
Min Cardinality: 0
Max Cardinality: *
Type: Encounter
Data Requirement Type: Patient
Profile(s): Patient
Data Requirement Type: Encounter
Profile(s): Encounter
Must Support Elements: type, period, status
Code Filter(s):
Path: type
ValueSet: Office Visit
Data Requirement Type: Encounter
Profile(s): Encounter
Must Support Elements: type, period, status
Code Filter(s):
Path: type
ValueSet: Annual Wellness Visit
Data Requirement Type: Encounter
Profile(s): Encounter
Must Support Elements: type, period, status
Code Filter(s):
Path: type
ValueSet: Preventive Care Services Established Office Visit, 18 and Up
Data Requirement Type: Encounter
Profile(s): Encounter
Must Support Elements: type, period, status
Code Filter(s):
Path: type
ValueSet: Preventive Care Services Initial Office Visit, 18 and Up
Data Requirement Type: Encounter
Profile(s): Encounter
Must Support Elements: type, period, status
Code Filter(s):
Path: type
ValueSet: Home Healthcare Services
Library Content
CQL Content
/*
This example is a work in progress and should not be considered a final specification
or recommendation for guidance. This example will help guide and direct the process
of finding conventions and usage patterns that meet the needs of the various stakeholders
in the measure development community.
*/
library AdultOutpatientEncounters version '2.0.000'

using FHIR version '4.0.1'

include hl7.fhir.uv.cql.FHIRHelpers version '4.0.1' called FHIRHelpers

valueset "Office Visit": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1001'
valueset "Annual Wellness Visit": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.526.3.1240'
valueset "Preventive Care Services - Established Office Visit, 18 and Up": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1025'
valueset "Preventive Care Services-Initial Office Visit, 18 and Up": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1023'
valueset "Home Healthcare Services": 'http://cts.nlm.nih.gov/fhir/ValueSet/2.16.840.1.113883.3.464.1003.101.12.1016'

parameter "Measurement Period" Interval<DateTime>
  default Interval[@2019-01-01T00:00:00.0, @2020-01-01T00:00:00.0)

context Patient

define "Qualifying Encounters":
	(
    [Encounter: "Office Visit"]
  		union [Encounter: "Annual Wellness Visit"]
  		union [Encounter: "Preventive Care Services - Established Office Visit, 18 and Up"]
  		union [Encounter: "Preventive Care Services-Initial Office Visit, 18 and Up"]
  		union [Encounter: "Home Healthcare Services"]
  ) ValidEncounter
		where ValidEncounter.period during "Measurement Period"
  		and ValidEncounter.status  = 'finished'
ELM XML Content
Encoded data (23740 characters)
ELM JSON Content
Encoded data (42732 characters)
Generated using version 0.4.9 of the sample-content-ig Liquid templates