These software packages all produce or consume tree sequences in the .trees file format.


Create tree sequences from models of biological processes

Simulate genealogical trees and genomic sequence data using population genetic models

ts = msprime.sim_ancestry(
ts = msprime.sim_mutations(ts, rate=1e-6)
Latest release: 1.2.0 1 week and 1 day ago
30 contributors

SLiM is a genetically explicit forward simulation software package for population genetics and evolutionary biology. It is highly flexible, with a built-in scripting language, and has a cross-platform graphical modeling environment called SLiMgui.

initialize() {
    initializeMutationType("m1", 0.5, "e", 0.001);
    initializeGenomicElementType("g1", m1, 1.0);
    initializeGenomicElement(g1, 0, 999999);
1 { sim.addSubpop("p1", 500); }
2000 late() { sim.treeSeqOutput("out.trees"); }
Latest release: v3.7.1 3 months and 1 week ago
12 contributors

Forward-time simulation in Python using fwdpp

Latest release: 0.18.0 yesterday
4 contributors


Create tree sequences from variation data

Infer a tree sequence from genetic variation data.

sample_data = tsinfer.load("phased_sequence_data.samples")
ts = tsinfer.infer(sample_data)
Latest release: 0.2.3 1 month and 2 weeks ago
10 contributors

Infer the age of ancestral nodes in a tree sequence.

dated_ts =
Latest release: 0.1.4 11 months and 1 day ago
3 contributors


Measure key statistics, manipulate tree sequences and their underlying tables

Population-scale genomics

ts = tskit.load("example.trees")
afs = ts.allele_frequency_spectrum()
Latest release: C_1.0.0 3 days ago
30 contributors

Tools for dealing with tree sequences coming to and from SLiM.

  rts = pyslim.recapitate(ts, ancestral_Ne=10000)
Latest release: v0.314 2 years and 5 months ago
10 contributors

rust bindings for tskit!

Latest release: 0.8.1 yesterday
4 contributors