Flatten the Curve
Posted onggplot2::
Introduction
I just wanted to write up a quick exponential growth model for my county. I have been saddened that the local department of public health has been underestimating the power of exponential growth.
Setting Up the Model
Just using some of the numbers that have been floating around (and cited in some recent literature that when I am not tired I will cite1) one can quickly simulate possible infections.
To build the model, I am going to take a reproductive rate of 2.28. Additionally, we can add some noise to this estimate in order to simulate 1,000 different scenarios. We know that we have two initial cases (more now as I write), so we’ll take that as
So we take the following model:
Where:
Additionally, for this simulation we will assume:
The Normal distribution might not be the best probability distribution to assume for this number (here’s where a split or two piece distribution would make sense because we know it might not be much lower but could be much higher.), but it will be a good start at least to get a sign and magnitude feel for the situation.
<-
possibilities <-
for(i in ){
possibilities <-
}
results <-
p<- results %>%
+
+
+
+
+
+
p
r0
Now when we talk about flattening the curve, if we can reduce the reproductive rate mean value from above 2 to one, we can see the following:
r0 <-
abatement <-
for(i in ){
abatement <-
}
results_abetment <-
p+
This is a much better situation. Regardless, we are still looking at a lot of sick people. The entire county could quite possibly be infected within the month, but at least there is some delay to allow our health system to compensate and put plans into place.
Hospital Capacity
Which really is the main point of it all: massive increases in the sick put huge stress on the hospitals and health care systems in general.
In Forsyth county we have two main hospitals Novant Forsyth (921 registered beds) and Wake Forest Baptist Medical Center (885 registered beds). All in that gives us 1806 beds. In reality, most hospitals operate at 80% capacity be it through staffing decisions (or inability to find nursing, etc) or through protection of surge capacity for just these types of issues.
Flow
For the sake of this simulation let’s assume that about 20% of the staffed beds turn over each day. Additionally, assume that there is some additional admit/discharge capacity. Here I mean how fast can the hospital actually process people (e.g. it takes time to move a patient, find a bed for them, go through the admission process. On the discharge there is some time spend arranging for placement, finding transportation, etc).
Now we can simulate the rough census or volume of patients in the hospital at any given time using the following simulation.
This is a very rough approximation of a hospital operations.
We have:
- Total number of beds
- Total number of staffed beds
- Our flow (generally speaking 20% of the hospital turns over per day)
- Convert flow to an hourly rate (which we will assume is Poisson distributed )
- Processing rate (which we will assume in normally distributed)
- Time horizon, here 28 days
Now we can run the basic simulation.
<- 921 + 885
staffed_beds <- n_beds * 0.8
flow_per_day <- staffed_beds * .2
flow_rate <- flow_per_day/24
intake_outtake_rate <- flow_rate
horizon_t <- 28*24
queue <-
queue <- staffed_beds*.8
for(i in 2:horizon_t){
admits <-
discharges <-
queue <- queue+admits-discharges
}
n_beds
This gives us the following census evolution.
Pretty stable, without saturating the system.
Now a Pandemic
Now we can our above pandemic simulation. Let’s also assume that each patient stays for 7 days. This means that we admit patients for seven days before they are discharged.
hospitalization_rate <- .05
covid_discharges <- *hospitalization_rate
covid_admissions <- *hospitalization_rate
queue_pan <-
queue_pan <- staffed_beds*.8
for(i in 2:horizon_t){
admits <- + covid_admissions
discharges <- - covid_discharges
queue_pan <- queue_pan+admits-discharges
}
saturation <-
We can see very quickly that saturates the healthcare system (actually the number patients outnumbers the number of beds available by day 9).
Now here is where it is important to flatten the curve. If we can lower the reproductive rate through the normal pathways: hand washing, social distancing, etc, we can see we will still have an issue:
hospitalization_rate <- .05
covid_discharges <- *hospitalization_rate
covid_admissions <- *hospitalization_rate
queue_pan <-
queue_pan <- staffed_beds*.8
for(i in 2:horizon_t){
admits <- + covid_admissions
discharges <- - covid_discharges
queue_pan <- queue_pan+admits-discharges
}
saturation <-
We can see that we still saturate the system by day 14, but at least we have a few more days. In reality, all of these models are approximations and are only realistic for short-term initial dynamics.
Conclusion
Pandemics are real, and locally we can control our own destiny. We need to be cautious and exercise care when dealing with these kinds of things and do our part to “flatten the curve”.
-
Like this study: Zhang, S, Diao M, et al (2020) ↩
Citation
BibTex citation:
@online{dewitt2020
author = {Michael E. DeWitt},
title = {Flatten the Curve},
date = 2020-03-13,
url = {https://michaeldewittjr.com/articles/2020-03-13-flatten-the-curve},
langid = {en}
}
For attribution, please cite this work as:
Michael E. DeWitt. 2020. "Flatten the Curve." March 13, 2020. https://michaeldewittjr.com/articles/2020-03-13-flatten-the-curve