Convert your FHIR JSON -> XML and back here. The CDA Book is sometimes listed for Kindle here and it is also SHIPPING from Amazon! See here for Errata.

Tuesday, February 14, 2012

Demonstrating Queries for Healthcare

I started actually writing the code yesterday for the Query Health demonstration at HIMSS next week.  I've been working on getting the model right for HQMF up until just before the IHE meetings last week, and have been playing with the I2B2 Demo system available on the web.  I've spent quite a bit of time THINKING about how to put it together, and now I've actually got some of it working.

The point of this part of the HIMSS demonstration is to show that it is easy to take the I2B2 query builder and generate HQMF from the I2B2 Query format.  One of the nice features of the I2B2 query building tool is the way you can use the <> button to see the messages that are being exchanged between the different services in I2B2.

Each I2B2 query is made up of panels.  Each panel is the logical OR of the criteria in it, and all the panels are logically ANDed together.  Each panel can be limited to a date range, which becomes the <effectiveTime> element on the criteria elements if present. Panels can also be toggled to exclude items that match their contents.  See the example below for how I handle that.  The I2B2 query interface doesn't deal with quality measure concepts like numerator, denominator, et cetera.  It just counts things that match, so all you really have is the <patientPopulationCriteria>.  A typical I2B2 query will be in the form:

  <!-- top level preconditions represent contents of a panel -->
      <!-- Inner preconditions are for each item in the panel -->
        <observationReference><id .../></observationReference>
  <!-- Eliminate nesting if only one item in the panel -->
    <observationReference><id .../></observationReference>
  <!-- If panel excludes content, invert logic using allFalse -->
        <observationReference><id .../></observationReference>

When run in I2B2, the query can return the set of patients, encounters, count of patients, with breakdowns by Gender, vital status, race and age.  It can also produce a timeline. I'm not dealing with returning set of patients or encounters, or timelines.  The breakdowns by gender, vital status, race and age are all what I've now called <stratifierCriteria> which enable counts to be reported by the different stratification criteria. I'm going to try to hook that up, but later.

For the demonstration, we are using the I2B2 sample ontology. Each item in each panel also has to be represented in the <dataCriteriaSection>  as a simple criterion over some part of the model.  Depending on where you are in the I2B2 ontology, that will map to a different part of the model that we are querying against in the generated HQMF.  At the top level, the I2B2 sample ontology includes:

  • Clinical Trials
  • Custom Metadata
  • Demographics
  • Diagnoses
  • Expression Profiles Data
  • Laboratory Tests
  • Medications
  • Procedures
  • Providers
  • Reports
  • Visit Details
The code I'm working will only support the components of the ontology in bold above, and only the italicized parts work right now.

Demographics expands into the following categories, which I map into <observationCritieria> using SNOMED Codes.

  • Age 
  • Gender
  • Income
  • Marital Status
  • Race
  • Religion
  • Vital Status
  • Zip Codes (misnamed)
Age is a bit weird.  The I2B2 ontology computes age based on the birth date and the mean Julian year (365.25 days).  This makes working with SQL easy, because you don't have to do fancy arithmetic for age ranges (and age ranges are also limited to being in units of years).  However, date arithmetic may be handled differently by the various implementations (Java and .Net have decent support for date math), while other systems may need to use Julian date arithmetic like I2B2 does.  I simply map the age ranges in the ontology to physical quantities of time, and that way, the implementation can decide how it will handle its date arithmetic.

For other parts of the ontology, I'm using the vocabulary from the I2B2 sample right now. When you get selective enough in the ontology, you can find a specific code in ICD-9-CM (Diagnoses and Procedures), LOINC (Labs), or NDC (for medications).  To get to the codes, my transform needs to access the ontology cell through the I2B2 web services.  For the demonstration, I'm pulling the XML I need from the service calls into local files on my system and accessing them using the XSLT document() function I wrote about in an earlier post.  Later I will access that through a RESTful web service also uses the document function.

Where it gets challenging is when you've not been specific enough (e.g., Hemoglobin, as opposed to HGB A1C, or a drug name such as Metoprolol vs. a specific NDC package code).  What I intend to do here is build a service that creates a value set based on an item key from the I2B2 Ontology cell, which enumerates all the coded values beneath it.  That's just another web service using IHE SVS that uses the I2B2 Ontology services to find the value sets.

Here's the release on the demonstration that this will be part of...

 NeHC University

A Message on Behalf of the
Standards & Interoperability (S&I) Framework
Query Health:  Distributed Population Queries
Query Health is an Open Government Initiative that is establishing the standards and services for distributed population health queries.  Query Health standards will be used to send questions to clinical data sources which return aggregate measures of population health that can be used for many purposes including disease outbreak monitoring, post-market surveillance, comparative effectiveness research, quality and performance measures. 
Query Health is pleased to announce the commitment of leading healthcare organizations to pilot the Query Health standards and specifications.  Query Health also plans to present its progress on proposed standards and reference implementation at the HIMSS conference in Las Vegas, February 20-24, 2012.  And in an unexpected twist, Query Health standards will deliver potential benefits beyond the scope of distributed population queries. 
Announcing the first Query Health Pilot
Today, Query Health is announcing that the Primary Care Information Project (PCIP), within the New York City Department of Health and Mental Hygiene, and the New York State Department of Public Health have announced plans to pilot the Query Health standards and reference implementation. PCIP recently won awards for their work on distributed queries including the 2011 HIMSS Public Health Davies Award of Excellence and Healthcare Informatics first place Innovator Award. They will be using Query Health standards to expand their existing population health monitoring network from an existing 1.6 million ambulatory patients to encompass citywide HIE organizational coverage of both inpatient and outpatient encounters. This enhanced system will support optimal allocation of limited public health resources.
What will be shown at HIMSS?
ONC will host a demonstration of Query Health’s progress on the reference implementation including a live demo of distributed query execution.
  • ONC Booth Theater on Wednesday February 22nd at 9:45 AM
  • HIMSS Interoperability Showcase Stage on Thursday February 23rd at 9:30 AM
Are there benefits beyond distributed population queries?
The path for a quality measure today is measured in years from the time of measure definition to delivery in vendor systems and deployment in EHRs.  Want another quality measure?  Wait several years.
In collaboration with HL7, NQF and CMS, Query Health standards will enable Health IT vendors to dynamically respond to queries, including queries that align with quality measures.  So assuming the data is being captured, the cycle time could go from years to days. 
The ability to generate measures nationally in a short cycle time has powerful benefits for patients, patient populations while enabling researchers and healthcare organizations to substantially reduce costs and increase speed.
What is Query Health?
Query Health was launched September 2011, with approximately 100 committed member organizations representing diverse healthcare stakeholders contributing to the project. 
Today, when health researchers develop questions about a population, in many cases they manually pose these questions to care delivery organizations, which employ technical teams to manually generate queries and produce reports. Even where distributed queries are automated, the costs and time to link each data source are unacceptably high.  The Query Health Initiative will make this much more efficient: the question can be delivered in a format that will be interpreted automatically by an HIT system. The HIT system will then generate a report with the “answer” to the query.
Questions can be sent to many different types of data sources including providers’ EHRs, payers’ clinical records, personal health records and health information exchanges.  Decisions about which queries to process are under control of the data owner and the aggregated results protect patient level data, which remains safely behind data owners’ firewalls. 
For more information:
For more information on Query Health initiative, visit the Query Health website or contact
The authors:
Michael Buck is the clinical work group leader for Query Health and director for the NYC/NYS pilot.  Dr. Buck is also Biomedical Informatics R&D Manager at New York City Department of Health and Mental Hygiene and Adjunct Associate Research Scientist at Columbia University’s  Department of Biomedical Informatics.  Rich Elmore is the ONC Coordinator for the Query Health Initiative.


Post a Comment