This is a simple simulation of malaria population dynamics over a two-dimensional geographic space. Points in the left panel show humans (they have either a 'red' or a 'blue' genotype). There are also mosquitos, who spend their time biting humans. To illustrate this, the biting radius of one of these mosquitos is shown by the green points.
At the start of the simulation, hosts and mosquitos are randomly initialised to have a single parasite each and each mosquito settles on a random human. We then let mosquitos bite and transmit parasites according to the following steps:
Parasites are assumed to have a genotype at one of a small number of bi-allelic genetic variants (controlled by the selector). Up to 5 variants (i.e. 32 parasite genotypes) are currently modelled. These variants are either assumed to be i. completely linked (i.e. no recombination between them) or ii. completely unlinked (as if they lie on different chromosomes) depending on whether meiosis is turned on.
The graph on the top right shows the number of infected individuals, and the number of individuals with mixed infections at the parasite variants considered. The graph on the bottom right shows the allele frequencies of each parasite genotype among all infected individuals.
Each human and mosquito can be infected with anywhere from zero to all of the parasite types. If bitten by an infected mosquito, humans become infected according to the 'Incubation success' probability (p). Co-infection and super-infection of humans is further controlled by the co/super-infection probability (q). A parasite infecting a host that is already infected with d parasite types, succeeds with probability p × qd.
Values of q near zero produce Wright-Fisher like dynamics (co/super-infection never occurs and so the allele frequencies sum to one. This produces strong competition between the alleles such that an increase in the frequency of one allele implies a decrease in frequency of the ohters.
On the other hand values of q near one produce no between-allele competition at all. In this case all alleles reach their own equilibrium frequencies essentially independently of the others.