Simulated data. (a) We simulated the genomes of 10 individuals grouped into 5 populations or species, labelled A, E, G, P and S. We segmented the genomes in blocks of 50 to 1000 nucleotides and assigned different local phylogenies at different frequencies, with the tree depicted in grey covering most of the genome and black the least coverage. (b) Shown is the comparison of Saguaro’s segmentation with the simulated truth (top). After iteration 16, Saguaro segments the genome correctly according to the simulation, with the exception of one block containing 9 SNPs. (c) We varied the divergence between genomes from 0 to 0.2 and computed the fraction of all nucleotides, including invariant sites, that was assigned to regions in which topology agrees with the simulation (green), disagrees (red), or falls in invariant regions at segmentation boundaries (blue).