To solve this problem, I import the records from these systems into a single simplified dataset called PatientEvents. The schema for this dataset consists of a patient identifier, an event type identifier, the date/times the event started and finished, and a freeform description field.
| Event Type | Start Date/Time | End Date/Time | Event Description |
| A & E Attendance | 12 Apr 2017 10:04 | 12 Apr 2017 11:47 | Service point: Ambulance Triage Primary Diagnosis: Dislocation/fracture/joint injury/amputation |
| Radiology Procedure | 12 Apr 2017 11:00 | 12 Apr 2017 11:06 | Specialty: ACCIDENT & EMERGENCY Modality: Radiology Exam Name: XR Finger Index Rt |
| Spell Admission | 12 Apr 2017 11:47 | 12 Apr 2017 11:47 | Admission Source: Usual place of Residence Admission Method: Emergency - Local A&E |
| Episode | 12 Apr 2017 11:47 | 12 Apr 2017 16:17 | Clinician transfer to Smith Z, Acute Medicine Primary Diagnosis: S631: Dislocation of finger Primary Procedure: W663: Primary manipulative closed reduction of fracture dislocation of joint NEC |
| Ward Stay | 12 Apr 2017 11:47 | 12 Apr 2017 13:53 | Ward transfer to ACUTE MED ASSESS UNIT |
| Clinic Appointment | 12 Apr 2017 13:10 | 12 Apr 2017 13:20 | Consultant: Jones, Z Specialty: Fracture Clinic: FRACTURE CLINIC Outcome: Future Appointment |
| Ward Stay | 12 Apr 2017 13:53 | 12 Apr 2017 15:33 | Ward transfer to AE ACUTE RESUS |
| Drug Administered | 12 Apr 2017 16:00 | 12 Apr 2017 16:00 | Item(s): PARACETAMOL 500 mg Tablets |
| Spell Discharge | 12 Apr 2017 16:17 | 12 Apr 2017 16:17 | Discharge Destination: Usual Place of residence |
Arranged in date order, the PatientEvents records can be read like a narrative of the patient's journey. When mapped onto a horizontal timeline, a user can intuitively correlate and cluster events.
| Presenting data on a timeline allows a user to quickly summarise the pathway and identify connections between events |
![]() |
| The Theatres group combines pre-op assessments (brown), surgical procedures (dark orange) and post-op electronic forms (light orange) |
![]() |
| Outpatient appointments are given a pale colour to indicate that they have been cancelled or DNAed |
Using the Patient Pathway Viewer, a user can quickly get an overview of a patient's hospital history, identify if they are a regular visitor, and see any future follow-up appointments they have booked in. All within a single window.
The Science Bit
I have designed the Patient Pathway Viewer to be as simple to implement as possible. I've written it using plain HTML/Javascript and it consumes data in a simple CSV format. I've set up a web service to provide this data, but it can be configured to use standard text files. This means that the software and data files can be hosted on any basic web server without the need for server side scripting.Because the software is intellectual property of Royal Liverpool and Broadgreen University Hospitals Trust, I'm not able to publish the viewer on the web or release the source code, but I've listed the Javascript libraries used below in the hope that it will help you recreate it, should you want to. I'm happy to answer any questions in the comments section.
Library
|
Description
|
License
|
JQuery
|
Provides much of
the cross-browser functionality
|
MIT
|
JQuery-CSV
|
JQuery plugin
which handles the conversion of CSV data files
|
MIT
|
CHAPS Links
Library Timeline
|
This drives the
timeline charts
|
Apache 2.0
|
JQuery-Layout
|
JQuery plugin
which fixes layout problems in legacy browsers
|
MIT
|
Moment.js
|
Handles date and
time formatting
|
MIT
|


No comments:
Post a Comment