|
| 1 | +--- |
| 2 | +title: "Implementing Interventions with epiworldRShiny" |
| 3 | +author: |
| 4 | + - Derek Meyer |
| 5 | + - George Vega Yon |
| 6 | +date: "`r Sys.Date()`" |
| 7 | +output: rmarkdown::html_vignette |
| 8 | +vignette: > |
| 9 | + %\VignetteIndexEntry{Getting started with epiworldRShiny} |
| 10 | + %\VignetteEngine{knitr::rmarkdown} |
| 11 | + %\VignetteEncoding{UTF-8} |
| 12 | +--- |
| 13 | + |
| 14 | +```{r setup, include = FALSE} |
| 15 | +knitr::opts_chunk$set( |
| 16 | + collapse = TRUE, |
| 17 | + comment = "#>", out.width = "80%", fig.width = 7, fig.height = 5, |
| 18 | + fig.align = "center" |
| 19 | +) |
| 20 | +``` |
| 21 | + |
| 22 | +# Example 2: Implementing vaccine and school closure |
| 23 | + |
| 24 | +## Running the application |
| 25 | +To run the epiworldRShiny application, first ensure that the package is |
| 26 | +installed and loaded using the following code. To launch the application, |
| 27 | +use call the function, epiworldRShiny(). |
| 28 | +```{r running-the-app} |
| 29 | +# install.packages("epiworldRShiny") |
| 30 | +library(epiworldRShiny) |
| 31 | +# epiworldRShiny() |
| 32 | +``` |
| 33 | + |
| 34 | +## Model set-up |
| 35 | + |
| 36 | +This example features the implementation of the vaccine and school closure |
| 37 | +interventions to curb disease spread. All model output can be interpreted using |
| 38 | +the same logic from example #1. |
| 39 | + |
| 40 | +- **Model**: network SEIRD |
| 41 | +- **Disease**: COVID-19 |
| 42 | +- **% of population infected** = 0.1 |
| 43 | +- **Probability of exposure** = 0.05 |
| 44 | +- **Recovery probability** = 0.14 |
| 45 | +- **Incubation days** = 7 |
| 46 | +- **Simulation time** = 100 |
| 47 | +- **Vaccine prevalence** = 70% |
| 48 | +- **School closure prevalance** = 50% |
| 49 | +- **Day of school closure implementation** = 7 |
| 50 | +- **Seed** = 2023 |
| 51 | + |
| 52 | +## Running the model |
| 53 | +```{r, echo=FALSE} |
| 54 | +knitr::include_graphics("https://github.com/UofUEpiBio/epiworldRShiny/assets/105825983/d5405162-f7fe-4a42-8a4c-e9a2ac31be73") |
| 55 | +``` |
| 56 | + |
| 57 | +The above graphic demonstrates launching the application and running the model |
| 58 | +with COVID-19 as the disease. To modify the intervention parameters, scroll to |
| 59 | +the bottom of the application sidebar, select "interventions", and modify as |
| 60 | +desired. After running the simulation, plots of the distributions of states and |
| 61 | +the disease's reproductive number over time, a model summary, and table of each |
| 62 | +state's counts over time are all displayed. |
| 63 | + |
| 64 | +## Results |
| 65 | + |
| 66 | +In this example, the model of choice is a SEIRD Network model. Notice the day of |
| 67 | +peak infections occurs on day 12, maxing out at 3,882 infections. Notice in |
| 68 | +the SEIRD model plot, there are very few exposed, infected, and deceased agents |
| 69 | +while the number of susceptible and recovered agents over the course of the |
| 70 | +simulation changes rapidly. Due to the vaccine, which decreases the probability |
| 71 | +of infection, and school closures which decrease the probability of exposure to |
| 72 | +COVID-19, there are a significantly decreased number of exposed, infected, and |
| 73 | +deceased agents. |
| 74 | + |
| 75 | +## Comparison to absence of interventions |
| 76 | + |
| 77 | +```{r, echo=FALSE, fig.show='hold',fig.align='center'} |
| 78 | +# library(cowplot) |
| 79 | +# library(magick) |
| 80 | +# ggdraw() + |
| 81 | +# draw_image("~/Desktop/intervention.png", width = 0.5) + |
| 82 | +# draw_image("~/Desktop/comparison_plot.png", width = 0.5, x = .5) |
| 83 | +
|
| 84 | +knitr::include_graphics("~/Desktop/Research/comparison.png") |
| 85 | +
|
| 86 | +``` |
| 87 | + |
| 88 | +The above SEIRD model figures demonstrate the distribution of states over time |
| 89 | +both with and without interventions present (left and right figures |
| 90 | +respectively). With no measure to combat the spread of COVID-19, the number of |
| 91 | +exposed, infected, and deceased individuals greatly increase compared to the |
| 92 | +model with interventions. The peak number of infections occurs earlier, on day |
| 93 | +11, with a total of 17,616 infections at the peak, compared to 3,882 infections |
| 94 | +on day 12 with interventions present. This indicates that the vaccination and |
| 95 | +school closing measures were effective in reducing the number of infections and |
| 96 | +deaths in this simulated population. |
0 commit comments