FHIR Data Visualization
Published Jun 09 2020 10:56 AM 3,243 Views

About Me

My name is Lim Zi Lian and I am a BSc Computer Science student at University College London. I was recently involved in the GOSH FHIRworks Hackathon 2020.



The main goal of the project was to speed up the auditing cycle in healthcare. The auditing cycle is a process used by health professionals to improve patient care in a systemic way through analyzing and evaluating data. A big part of the auditing cycle is to collect data, whether from computerized or physical records, and visualizing data for analytical purposes which can be slow depending on the region. The solution is to provide an intuitive dashboard for relevant parties to access information from the FHIR database with ease, allowing users possessing minimal technical skills to utilize the analytic features even during the early stages of adopting the program.


The development cycle involves various steps from short consultations with a few practicing doctors to identify key data to designing and wireframing a straight-forward design as to not impede the usage of the dashboard.


The source code for the project can be found on GitHub at                   https://github.com/SteveLim99/GOSH-FHIRworks2020-FHIR-Data-Visualization


A brief video on the project can be found on YouTube at https://www.youtube.com/watch?v=q3PW26utQ-4&feature=youtu.be


My Approach

I first identified the data that is available on the FHIR database and had quick consultations with a few practising doctors to understand the different types of data that is relevant to the auditing cycle and patient consultation. Such data included age groups, pain severity, medications etc. A common mnemonic acronym used amongst doctors is SOCRATES which stands for:

  • S  : Site of pain
  • O : Speed of Onset
  • C  : Character of pain
  • R  : Radiation of pain
  • A  : Alleviating factors
  • T  : Timing
  • E  : Exacerbating factors
  • S  : Pain Severity 

Due to the limitations and amount of synthetic data provided during the Hackathon, I was not able to include all relevant data to SOCRATES or medication information to generate more precise and relevant graphs.


For the program to be easily accessible without the need for any in-depth technical expertise or intense training, I kept the design of the application simple and easily navigable. After going through a few design sketches, I settled on the design as shown in figure 1.0 and figure 1.1 due to its simplicity and cleanliness. Setting the design aside, the data displayed on the web application is obtain through a few API endpoints that I have created which returns relevant data regarding a specific patient or demographic group after processing the data from the FHIR database.



[Figure 1.0]



[Figure 1.1]


For demographic groups, there is a helper function that is reponsible for generating the colors of the graph, this is due to the varying number of groups found on the FHIR database for different demographics. Hence, to accommodate for any number of parameters, a color generator was requried to interpolate a range of colors for the graphs. This can be observed in figure 2.0 and figure 2.1.



[Figure 2.0]



[Figure 2.1]


Technical Solution



[Figure 3.0]


Figure 3.0 is the system architecture diagram of the project; I chose to develop the web application in Python due to the simplicity and versatility of the language allowing me to manage my time on other sections of the program better to keep within the time constraint of the hackathon. I used Flask for the web framework due to the following:

  • As I did not require a lot of extensions, flask was ideal as it was lightweight, modular and highly flexible allowing me to create my web application quickly.
  • Flask handles HTTP request easily allowing me to focus more on creating the algorithm behind the API endpoints that parses and process data from the FHIR database. This allowed me to rapidly develop the API with minimal setup.
  • Due to its lightweight nature, Flask is significantly faster as compared to Django.

Learning Points

  • Development of APIs
  • The importance of the data visualization and the auditing cycle in revealing trends and patterns in healthcare for the improvement of patient care and existing health systems.

Final Thoughts

Given more time and access to data on the FHIR database, I would have include clinical and medications data which would allow me to create more precise demographic groups such as blood pressure across age groups, the symptoms related to a certain medication, greater detail of SOCRATES, etc. Nonetheless, the hackathon has been an exciting and challenging experience, the project showed me the potential of the FHIR database. I really appreciate the feedback I obtained from GOSH and the Microsoft FHIR team in Seattle, and the opportunity to showcase my solution.

Version history
Last update:
‎Jun 09 2020 10:56 AM
Updated by: