π Quick start
Start here to explore the model and see how it works. This example is deliberately small and unrealistic: 3 human hosts (--Nh), 10 generations (--T), 2 parasites per bite (--K), a superinfection probability of 0.18 (--chi) and 1 oocyst per mosquito (--C). At this size you can clearly see each host, each generation, and how parasites are transmitted between them. To explore how the model behaves at a realistic scale, and the distributions it produces, see Real-scale dynamics.
Run the notebook
The Jupyter notebook runs every krsim command on this example and looks at what each one writes. Change the parameters to see how transmission changes.
Open it in Google Colab (needs a Google account); there is nothing to install. Run the first cell, which installs krsim, then run the rest with Runtime β Run all.
With the krsim environment active (Installation), run the commands below. The first saves the notebook into your current folder and the second opens it in Jupyter:
curl -O https://raw.githubusercontent.com/mrc-ide/KR_simulator/main/notebooks/tutorial.ipynb
jupyter notebook tutorial.ipynbThe notebook writes its files to output/ next to it.
Visualise transmission
The notebook also draws two interactive maps of the true pedigree. These are the maps from this example (seed 123); both are interactive, so you can try them here.
Pairwise strain pedigree map. Pick two current strains and trace each oneβs ancestry back through the pedigree. Where the two lineages meet are their shared ancestors. Open full screen
Strain transmission and mutation map. Who infected whom, generation by generation: founders at the top, current strains at the bottom, one lane per host. Each Γ is a mutation, drawn on the link and at the time it happened. Pick a chromosome, then a tree in the bar, to see just the genealogy of that stretch of genome and its mutations; click a strain to highlight its ancestors and descendants. Open full screen
Next: try the command-line scripts for the same example, or see how the host VCF gets realistic read depth.