-
Notifications
You must be signed in to change notification settings - Fork 646
COVID 19 Related Simulation
Synthea provides simulation of SARS-CoV-2 infection, progression to COVID-19 and vaccination. Given the recency of the COVID-19 pandemic, Synthea is able to leverage real-world data to simulate infection and vaccinate rates.
The infection rate for SARS-CoV-2 is driven by data obtained from the Our World In Data GitHub Repository (OWID). The OWID data set provides daily COVID-19 case counts as well as the rate of cases per 100K. While the dataset provided by OWID is for the entire world, Synthea currently uses data for the US. The probability of an unvaccinated individual contracting a SARS-CoV-2 infection on a given day in the simulation is the US national case rate per 100K divided by 100K.
Infections happen in the Synthea COVID-19 Module. This module uses a CSV look up table, covid19_prob.csv
, for infection rates.
Individuals who are vaccinated in the simulation are 100 times less likely to be infected. This figure was arbitrarily chosen by the Synthea team and may be updated as data on vaccine prevention of infection is made available and agreed upon by the scientific community.
The Synthea project provides a method for updating case count data. Users can run the update_case_counts.js
script, contained in src/main/javascript
. This script will fetch the case count data from GitHub and update covid19_prob.csv
. The script requires node.js (the script was tested with version 16.5.0) and curl to be installed.
Synthea simulates COVID-19 vaccination as it has been rolled out to the population of the US. Synthea will make a vaccine available in the simulation on the date it received EUA from the FDA. Individuals will be eligible to be vaccinated, based on their age in the simulation and the relevant EUA rules in place during that time. The time at which an individual in the simulation will receive a vaccination is based on their age and the rate at which individuals in their age range were vaccinated in the US. This information is obtained from data.cdc.gov.
Vaccination logic is driven by the org.mitre.synthea.modules.covid.C19ImmunizationModule
. A high level overview of this logic is:
- Wait until December 11, 2020 before doing anything. This was the date of the first EUA for COVID-19 in the US.
- Determine if the individual is eligible based on age, given the time in the simulation.
- If they are eligible, determine whether they will get vaccinated. This is a randomly weighted selected, with the probability of the individual being vaccinated equivalent to the national percentage of individuals in their age range who have had at least one vaccine dose.
- If the individual will be vaccinated, select a date for their vaccination, based on vaccination date distribution data
- Select a vaccine (Pfizer-BioNTech COVID-19 Vaccine, Moderna COVID-19 Vaccine or Johnson & Johnson (Janssen) COVID-19) based on national statistics on vaccine usage.
- Wait until the selected vaccination date
- Check if the individual has an active COVID-19 case
- Administer vaccine if there is no COVID-19 active, or COVID-19 has resolved
- Administer second dose for Pfizer-BioNTech COVID-19 Vaccine or Moderna COVID-19 Vaccine at the appropriate timing
Individuals who initially do not obtain a vaccination, will transition into the logic provided by org.mitre.synthea.modules.covid.LateAdopterModel
. This transition will happen in the simulation at the time specified by C19ImmunizationModule.LATE_ADOPTION_START_TIME
. The logic provides a chance that the individual will seek vaccination for a time in the simulation for which Synthea does not have real world data. The chance for age ranges was arbitrarily chosen by the Synthea team, with those under 16 years old starting with a probability of 0.4 of seeking vaccination given the short window of time it has been available. The chance that an individual will be vaccinated drops by half every two weeks in the simulation. Eventually, when the probability drops below 0.001 in the simulation, the individual will enter a state where they will never be vaccinated.
The Synthea project provides a method for updating vaccination data. Users can run the update_covid_stats.js
script, contained in src/main/javascript
. This script will fetch vaccination data from CDC and update covid_dose_rates.csv
as well as covid_first_shot_percentage_by_age.json
. The script requires node.js (the script was tested with version 16.5.0) and requires the npm packages axios and csv-writer to be installed.