Skip to content

Commit

Permalink
just update readme and vignettes
Browse files Browse the repository at this point in the history
  • Loading branch information
hillalex committed Oct 4, 2024
1 parent 37b30e6 commit 3a8d8f8
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
23 changes: 22 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,23 @@
# epikinetics
[![Project Status: WIP – Initial development is in progress, but there has not yet been a stable, usable release suitable for the public.](https://www.repostatus.org/badges/latest/wip.svg)](https://www.repostatus.org/#wip) [![R-CMD-check](https://github.com/seroanalytics/epikinetics/actions/workflows/check-standard.yaml/badge.svg)](https://github.com/seroanalytics/epikinetics/actions/workflows/check-standard.yaml) [![codecov](https://codecov.io/gh/seroanalytics/epikinetics/graph/badge.svg?token=5MZYYDUZYH)](https://codecov.io/gh/seroanalytics/epikinetics)

`epikinetics` is an R package for Bayesian hierarchical modelling of antibody kinetics.

The underlying model is taken from [Russell TW et al., Real-time estimation of immunological responses against emerging SARS-CoV-2 variants in the UK: a mathematical modelling study.](#References)
See the [case study vignette](https://seroanalytics.org/epikinetics/articles/biokinetics.html) for a replication of some key figures from the paper using `epikinetics`.

Three publicly available datasets from the above paper are also installed with the package and
can be used as test input data:

```{r}
delta <- data.table::fread(system.file("delta_full.rds", package = "epikinetics"))
ba2 <- data.table::fread(system.file("ba2_full.rds", package = "epikinetics"))
xbb <- data.table::fread(system.file("xbb_full.rds", package = "epikinetics"))
```

If running the model with your own data, see the [data vignette](https://seroanalytics.org/epikinetics/articles/data.html) for
an explanation of the input format.

# Installing

This package uses `cmdstanr`, which isn't available on cran, so you will first have to install it as follows:
Expand All @@ -20,7 +37,8 @@ remotes::install_github("seroanalytics/epikinetics")
Alternatively, you can run `epikinetics` via a Docker image, mounting a working directory which contains your input data files:

```
docker run -v /workdir:/ -it seroanalytics/epikinetics:main
docker pull seroanalytics/epikinetics:main
docker run -v /path/to/local/workdir:/workdir -it seroanalytics/epikinetics:main
```

# Developing
Expand All @@ -35,3 +53,6 @@ local changes you have to actually run `devtools::install()`.
To build a Docker image, run `docker/build`.
To push a new image to Dockerhub, `docker/push`. An image is built and pushed
during CI on merge to main.

# References
Russell TW, Townsley H, Hellewell J, Gahir J, Shawe-Taylor M, Greenwood D, Hodgson D, Hobbs A, Dowgier G, Penn R, Sanderson T, Stevenson-Leggett P, Bazire J, Harvey R, Fowler AS, Miah M, Smith C, Miranda M, Bawumia P, Mears HV, Adams L, Hatipoglu E, O'Reilly N, Warchal S, Ambrose K, Strange A, Kelly G, Kjar S, Papineni P, Corrah T, Gilson R, Libri V, Kassiotis G, Gamblin S, Lewis NS, Williams B, Swanton C, Gandhi S, Beale R, Wu MY, Bauer DLV, Carr EJ, Wall EC, Kucharski AJ. Real-time estimation of immunological responses against emerging SARS-CoV-2 variants in the UK: a mathematical modelling study. Lancet Infect Dis. 2024 Sep 11:S1473-3099(24)00484-5. doi: [10.1016/S1473-3099(24)00484-5](https://doi.org/10.1016/s1473-3099(24)00484-5).
5 changes: 5 additions & 0 deletions vignettes/data.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,19 @@ The model requires a data table containing the following columns:

### pid
A unique numeric id to identify a person across observations

### date
The date of the observation

### last_exp_date
The last date on which the person was exposed

### titre_type
The name of the titre

### value
The value of the titre

### censored
Whether this observation should be censored: -1 for lower, 1 for upper, 0 for none

Expand Down

0 comments on commit 3a8d8f8

Please sign in to comment.