RADx-sim 0.11
A stochastic agent-based model to simulate SARS-CoV-2 epidemics.

# Rapid Antigen Diagnostics (RADx) model
---
RADx is a stochastic agent-based modelling framework developed to investigate the impact of using SARS-CoV-2 antigen rapid diagnostic tests (Ag-RDTs) in communities with demographic profiles, contact mixing patterns, levels of public health resources mirroring those often observed in low- and middle-income countries (LMICs). RADx has been used in the Phase 2 study of the World Health Organization (WHO) and Foundation for Innovative New Diagnostics (FIND)’s Access to COVID-19 Tools Accelerator (ACT-A) SARS-CoV-2 diagnostics modelling consortium.  This study interrogates how different Ag-RDT availability and distribution strategies, including the implementation of community testing in households, schools, formal workplaces and regular mass gatherings (e.g. churches), as well as post-testing behavioural changes and public health interventions could impact onward disease transmissions and pandemic mitigation

The analyses codes for the ACT-A Phase 2 study be found as a Jupyter Notebook [here](https://github.com/AMC-LAEB/RADx-sim/tree/main/ACTA_phase2)

RADx can also simulate the spread of up to two SARS-CoV-2 variants with different viral and transmission properties (e.g. incubation and infection periods, maximum within-host viral load, disease severity, relative transmissibility, etc.). As such, RADx can also be used to perform other COVID-19 analyses. We have thus used RADx to investigate how testing capacities, access to healthcare facilities and sequencing frequencies jointly impact the effectiveness of pathogen surveillance. This work and the original scientific paper describing RADx can be found [here](https://link) and cited as:
>

The analyses codes for this paper can be found as a Jupyter Notebook [here](https://github.com/AMC-LAEB/RADx-sim/tree/main/surveillance)

If you have questions or comments, please email to <x.han@amsterdamumc.nl>.

## Requirements and installation of RADx-sim
---
```RADx-sim``` minimally requires Python 3.7 and Cython 0.29.23. Before installation, install cython by ```pip```:

```pip install cython```

```RADx-sim``` can also be installed as a ```pip``` package:  
```pip install RADx-sim```

If installation by ```pip``` fails, you may also clone this repository in your local drive and install by:

```
git clone https://github.com/AMC-LAEB/RADx-sim
cd RADx-sim
python setup.py install --record installed_files.txt
```

## Basic usage
---
### Simulate SARS-CoV-2 epidemic
1. Fill in demographic and transmission parameters in the example spreadsheet provided (```radx_input_file.xlsx```).
2. Run simulation for _N_ number of days:
```runradx.py simulate --input radx_input_file.xlsx --ndays N```

### Simulate genomic surveillance from previously simulated epidemics
1. Suppose you had previously used RADx to simulate an epidemic and the results are stored in the path ```RADx-sim_output```.
2. Run genomic surveillance simulations (```N``` number of random boostraps) assuming ```f``` fraction of healthcare facilities as tertiary facilities (i.e. assumed that only tertiary facilties have capacities and resources to perform genome sequencing), ```s``` fraction of samples collected are being sequenced weekly:
```runradx.py gs --resfolder RADx-sim_output --tertiary_hcf_prop f --seq_prop s --gs_sim_N N```