MJomaba / flu-evidence-synthesis

Code for reconstructing influenza dynamics from surveillance data using evidence synthesis techniques
19 stars 10 forks source link

fluEvidenceSynthesis

This repository contains the fluEvidenceSynthesis package which was described in more detail in:

van Leeuwen, Edwin, Petra Klepac, Dominic Thorrington, Richard Pebody, and Marc Baguelin. “FluEvidenceSynthesis: An R Package for Evidence Synthesis Based Analysis of Epidemiological Outbreaks.” PLOS Computational Biology 13, no. 11 (2017): e1005838. https://doi.org/10.1371/journal.pcbi.1005838.

The code is distributed under a GPLv3 license. Please remember to cite the above manuscript when using this code.

Install

Devtools

First make sure you have the devtools package install in R by executing the following in R:

install.packages("devtools")

Note that devtools relies on a fairly new R version (>=3.1.0). Devtools also relies on a number of packages and one can run into problems installing it. Please refer to their documentation when encountering problems.

FluEvidenceSynthesis

Then use devtools to install fluEvidenceSynthesis by using the following command:

library(devtools)
install_github("MJomaba/flu-evidence-synthesis", dependencies = TRUE)

The above will install the package without the vignettes. To install them as well you first need to install odin following these instructions, because one of the vignettes depends on that package. After installing odin you can install the package and its vignettes as follows.

library(devtools)
install_github("MJomaba/flu-evidence-synthesis", dependencies = TRUE, build_vignettes = TRUE)

Documentation and examples

All functions provided by the package are documented in R, but we recommend reading the provided vignettes for a good introduction/overview of the provided capabilities. Vignettes on the epidemiological model and parameter inference can be found here, here and here. There is also a vignette available on analysing the effects of different vaccination scenarios.

If you also installed the vignettes locally (see above) you can view them using:

# To list the included vignettes:
vignette(package="fluEvidenceSynthesis")

# To open the inference vignette:
vignette("inference",package="fluEvidenceSynthesis")

There is also a presentation available with some more details on the package here.