The dynamic course of subclinical and symptomatic heath features as a condition progresses or responds provides insights on health and disease severity and the efficacy of trialed interventions. Electronic Health Data (EHD) includes clinically captured physiological values, laboratory values, and genetic information, as well as patient recorded information such as blood pressure and food logs, and continuous physiologic data from wearable devices. The increasing amount of data being collected on individuals’ health should empower patients and clinicians with Clinical Decision Support (CDS) tools; however, most of the data collected by patients from logs, consumer wearable devices, and medical grade devices cannot be aggregated. Information retrieval systems that integrate multiple data streams have been developed for particular applications, but there is no system that permits flexible retrieval and interactive visualization of all EHD data streams. To address this problem, we introduce EHDViz: an R-based opensource sparkline dashboard that interactively displays information from multiple EHD streams. On this site we share several examples of use scenarios of this platform and provide a link to the source code that can modified for your particular application.

How To Use

EHDViz is a flexible framework that can be customized for different use scenarios with respect to data input approach, data pre-processing, dynamic UI, and visualization. Here we will review the basic specifications and principles for customization.

Input Format:
The data input format is a "wide" table (ie, tsv, csv, data_frame.Rdata) for each data source, where each row specifies a measurement time and each column contains a single variable of metadata (ie, patient #) or data (ie, Heart Rate). Examples of these input formats can be found here and downloaded from github here.

The rows and columns can be found in any order, but the column names must follow a specific pattern for the timing and metadata to be parsed correctly:
Time stamp data must have the column name "timing".
Metadata variables the user wishes to select by in a dropdown menu must have column names "sel_foo" where foo is the variable name.
Metadata variables the user wishes plots to be colored by must have column names "col_bar" where bar is the variable name.
There should be one data column for each health feature that is measured, which can be named anything that doesn't include the pattern "timing", "col_", or "sel_". These column names are put into a multiselect dropdown menu so the user can pick the features of interest.

Input Source:
We demonstrate two approaches to input data sourcing, although many others can be implemented through R. Most of our applications use data saved in a folder with the application, and the quantified self application scrapes a webpage every time the app is run. To use a different input, you can save the data table in the data folder and change the input line of the ui.R and server.R scripts to import this new data. Alternative you can run a few commands at the beginning of the app to download and format a table from a URL, JSON files, etc.

User Interface:
The user interface is specified by the ui.R script. Our UI allows the user to select various input filters (metadata via single choice selections and health features via multiselect options) and displays one multiplot for each data source. For the quantified health implementation, we provide separate user filtering panels and multiplots for each data source. For the medicine icd9 based information retrieval implementation, we provide a reactive user input panel which changes depending on the user selected icd9 class.

Sample Input

PT Log:

"Timing" "Weight" "Blood_Pressure"
2015-03-30 16:28:27 200.390345454749 123.797632736852
2015-03-30 16:28:27 200.128866985118 123.797632736852
2015-03-30 16:28:27 200.113613361934 123.797632736852
Download Sample PT Log Input Here

Provider EMR:

"Timing" "sel_Patient_Name" "col_location" "19076-9:# CELLS COUNTED" "65761-9:% T CYTO/SUPP" "24467-3:% T HELPER" "65761-9:ABS T CYTO/SUPP"
2015-03-29 16:06:34 "John_Doe" "ED" 117.154806635892 48.2648814262602 41.9848648497638 797.361254868914
2015-03-29 16:06:34 "John_Doe" "ED" 117.154806635892 61.2648814262602 59.9848648497638 1223.36125486891
2015-03-29 16:06:34 "John_Doe" "ED" 117.154806635892 48.2648814262602 62.9848648497638 1094.36125486891
Download Sample Provider EMR Input Here


"Timing" "Blood_Pressure" "Respiratory_Rate" "Heart_Rate" "Weight" "Cholesterol" "col_Visit_Type"
2015-03-30 16:28:27 120.129788041884 15.3441599941206 65.2859107423789 200.164706346676 121.547228089059 "Primary Care Physician"
2015-03-30 16:28:27 126.725945560207 15.6471289094226 65.1009927376515 200.28691961203 124.91081702972 "ER"
2015-03-30 16:28:27 127.650568212876 15.567303609334 65.6698874300989 200.278997106229 129.015750806846 "Urgent Care"
Download Sample PT EMR Input Here


Quantified Self:
1: User management; 2: Dynamic selection; 3: Integration with data streams; 4: Integration with manual data input

Clinical Evaluation:
1: Selection of individuals; 2: Options to control visual layouts; 3: Integration with ICD-9 code

Population Health Management:
1: Visualization of data from floor using admission-discharge-transfer data; 2: Dynamic control of visualization; 3: Real-time user interaction