A stochastic, Wright-Fisher-based model, built with C++.
Investigating the effect of recombination on the rate of emergence of multi-drug resistance under different treatment strategies (single treatment, cycling treatment, and multiple firstline therapies (MFTs) in Malaria.
Includes python scripts for simple inference and visualizations in data/plotting/.
mkdir build
cd build
cmake -S ../src -B .
make
./MalariaPopSim
- In
fitness_values.csv: Adjust fitness of wildtype clones according to assumed length of transmission cycle - In
simulator.cpp: starting clones and starting clone frequencies - In
settings.h: everything else (demography, genetics map, recombination, treatment)
| Frequency of each clone per generation | Disease prevalence per generation | Frequency of resistant clones per generation | |
|---|---|---|---|
| Cycling | ![]() |
![]() |
![]() |
| Multiple Firstline Therapies (MFTs) | ![]() |
![]() |
![]() |
Assumes a pool of Malaria clones and a population of exchangeable hosts. It is stochastic and iterates discrete time steps equivalent to one Malaria generation/transmission cycle, which is approximately 28 days in high transmission regions.
The model can be divided roughly into the following five modules.
-
Multiplicity of Infection (MOI): each host is assigned a MOI drawn from a poisson distribution with poisson mean
$\lambda$ -
Selecting clones: each host selects MOI times from the clone pool with chance of selecting clone equal to that clones frequency in population
- each clone has frequency
$\frac{1}{\text{MOI}}$ within host (total frequency = 1) - same clone can be selected multiple times
- each clone has frequency
-
Selecting drugs
- Single drug strategy: all hosts receive one drug
- MFTs strategy: each drug is distributed evenly across host population
- Adaptive cycling strategy: all hosts receive one drug, until mean fitness of population is greater than average fitness of all clones to current drug, at which point all hosts swap to another drug
Each host is assigned a mean fitness
where
Fitness values are drawn from Appendix 2 of Nguyen et al. 2023 The untreated fitness values for clones are calculated as:
where
We assume mosquitoes (not simulated) pick up Malaria clones in exactly the frequency that they were in after selection within the host. We don't consider interrupted feeding.
A parameter
Every possible clone pair produces sexual offspring with frequency equal to the probability of their parental pairing divided by the total number of recombinants given no linkage. Therefore, during sexual recombination, complete recombination occurs - i.e. parental clones are completely split up into possible recombinants.
Currently, the only loci exhibiting linkage in the model are Y184F and N86Y - both at pfmdr1 on chromosome 5. pfmdr1 has 1 exon, meaning the sites are 294bp apart.
Using the genetic map estimate of
The new global frequency of each clone
where
The poisson mean in the next generation (
In the model, mutations occur in the global pool of clones rather than within hosts. This means mutants do not recombine unless selected by chance by a host in the next generation.
We assume no backwards mutations and 1 allele is mutated (if not already mutant) for each mutant clone. The initial frequency of a single mutant is
The frequency of each mutant is:
and the original parent clone has new frequency:





