Case Study: Data Visualization Capabilities as Demonstrated in Synthetic Health Patient Records

Case Study: Data Visualization Capabilities as Demonstrated in Synthetic Health Patient Records


Wellness visits, or yearly checkups, are a form of preventative healthcare that has seen increased adoption and promotion within the healthcare industry. Many insurers completely cover wellness visits for which the subscriber does not even have to pay their co-pay. We analyzed several facets of healthcare, including prescriptions, doctor visits, medical device usage, covered costs, practitioners’ information, and patient records, to uncover data insights with the goal of demonstrating Stout’s capabilities in visualizing data insights using Power BI.


We analyzed 17 large datasets (a total size of approximately 8 GB) that we generated using an open-source synthetic patient data generator called Synthea[1]. The datasets contained electronic health records (EHRs), prescriptions, patient visits, diagnostic codes, healthcare practitioner information, and health insurance medical claim details. We used RxNav, the National Library of Medicine repository of standard names for clinical drugs, to classify prescriptions. 188 inputs were used in the analysis, along with several techniques to handle missing or incomplete data. We also used the Python programming language to create relationships and correlations among all datasets.

The data used for our dashboards do not correspond to real patients, so we are free from privacy and security restrictions. However, the synthetic datasets are not random: the framework for generating the datasets uses publicly available data sources and health statistics (including US Census Bureau demographics, Centers for Disease Control and Prevention prevalence and incidence rates, and National Institutes of Health reports). It also employs clinical guidelines and methods that preserve realistic properties in synthetic EHRs. The datasets use coded entries in the Health Level-7 (HL7) Fast Healthcare Interoperability Resources (FHIR) standard format, and all EHRs correspond to the residents of a virtual Commonwealth of Massachusetts.


The graphs below demonstrate Stout’s capabilities in uncovering insights using large datasets and Power BI to visualize the insights.

Figure 1: Patient encounters are the interactions between patients and medical professionals. Understanding the distribution of different encounter types helps paint a picture of the most relevant, highest revenue-generating fields in a region. In this case, the top three types of patient encounters are wellness, ambulatory, and outpatient. Wellness visits - interactions between general practitioners and their patients. Example: annual physical checkup with a physician. Ambulatory care - Medical services performed on an outpatient basis, without admission to a hospital or other facility. Outpatient visits - visits in which a patient does not spend the night at a care center.

*The encounter types used the HL7 encounter codes from the HL7 FHIR specs.

[1] Jason Walonoski, Mark Kramer, Joseph Nichols, Andre Quina, Chris Moesel, Dylan Hall, Carlton Duffett, Kudakwashe Dube, Thomas Gallagher, Scott McLachlan Synthea : An approach, method, and software mechanism for generating synthetic patients and the synthetic electronic health care record, Journal of the American Medical Informatics Association, Volume 25, Issue 3, March 2018, Pages 230–238

Figure 2: Patient encounter types each have unique costs and unique propensities for insurance coverage. Analyzing the discrepancy between the average cost of an encounter and the average insurance payout for the encounter helps highlight the fields in which insurance companies are most liable. For example, wellness visits between patients and their general practitioners tend to have higher rates of coverage than ambulatory visits. This difference is expected because annual physicals are more predictable and therefore easier for insurance companies to cover.

*The encounters billed used the average prices from the National Institutes of Health.

Figure 3: To examine the average costs and rates of coverage for different encounter types over time, we designed a dynamic scatterplot with values from the years 2000 to 2021. This year-over-year analysis demonstrates when each encounter type has its highest and lowest rate of coverage over that period. Data visualization shows that wellness encounters consistently fall near the "full coverage" line, while ambulatory visits, for example, have lower coverage and are visibly farther away from the line. Some other encounter types, such as emergency room visits, have stationary ratios of cost to coverage over the years. Understanding the behavioral trends in medical insurance coverage for different encounter types helps identify potential areas of new coverage.

Figure 4: Knowing a person's age can help researchers understand their likelihood of engaging in each type of encounter class. The tree map of age groups and their corresponding encounter class ratios sheds light on some interesting trends and insights. For instance, it indicates that wellness visits and outpatient visits are inversely correlated. Without extrapolating causation, we could at least claim that age groups with higher proportions of wellness visits tend to require fewer outpatient visits. Therefore, under a controlled study, we would expect people who have more frequent physical checkups to be less likely to make visits to the hospital. Also, people tend to schedule more wellness visits as they get older (starting at age 35 and ending at age 75), and ambulatory visits are surprisingly common across all age groups.

Figure 5: The scatterplot of average encounter cost to number of wellness encounters per patient demonstrates a definitive trend. As patients accumulate more wellness visits, their average cost per visit tends to be lower, thus indicating a cost savings associated with attending dedicated physical checkups. This information, in conjunction with the insight that wellness visits are inversely correlated with outpatient visits, contributes to the idea that scheduling annual checkups can keep someone healthy at a diminishing cost over time.

Figure 6: Investigating a bucketed histogram of wellness encounters per patient versus other encounter types also shows that across the board, other medical encounter types are highest when a patient has more wellness visits. Patients with a greater number of wellness visits tend to be older and are also at the highest risk of running into other medical complications.

Complete the form to talk to our professionals: