individuals form a clade with respect to reference groups. The reason 
why this is a principled approach despite the 1000GP groups post-dating 
the ancient individuals is that if a group of ancient individuals are truly 
homogeneous, they will be so also with respect to later individuals.
We then define clusters by running UPGMA (unweighted pair group 
method with arithmetic mean) on −log 10[P values] obtained from 
qpwave between all pairs of individuals and cut the resulting dendro-
gram at a height corresponding to a P value of 0.01. We then further 
subdivide clusters by requiring all samples to be within 500 years of 
the mean cluster age.
T o choose the source groups shown in Fig. 2a and Extended Data 
Fig. 1d, we run this algorithm on samples from Iron and Roman Age 
Europe (Supplementary Table 1). We retain groups that have at least 
three individuals and, therefore, exclude clusters of size one or two.
This approach results in two clusters in the Scandinavian Penin -
sula, approximately separating northern from southern Scandinavia, 
three clusters in Poland and Ukraine that separate samples tempo-
rally between the early and later Bronze Age, a cluster combining the 
Hungarian Scythian and Slovakian La T ène-associated individuals, 
and a cluster each for Iron and Roman Age Portugal, Italy and Lithu-
ania. In present-day Austria, Germany and France, this approach 
identifies three clusters, with each cluster spanning multiple archae-
ological sites in different countries, indicating genetic diversity in 
this region in the first millennium ce. Encouragingly, these clusters 
separate in our non-parametric MDS analysis (Fig. 2a), indicating that 
we are capturing real genetic differences between groups using this  
approach.
Fine-scale structure in Neolithic Europe. T o quantify fine-scale struc-
ture in Neolithic Europe (Extended Data Fig. 5b), we aimed to select 
individuals in Neolithic Europe who have not yet been affected by the 
arrival of Steppe ancestry and do not show excess hunter-gatherer 
ancestry. We infer distal ancestry sources using Balkan_N, Yamnaya and  
Western Hunter-gatherers as source groups and reference groups  
according to a previously proposed qpAdm setup46 (Supplementary 
Table 1). For this analysis, we infer ancestry using qpAdm applied to  
1.2 million SNP sites of imputed genomes. We retain only Neolithic 
individuals with P  > 0.01, z < 2 for Yamnaya ancestry, and z  < 2 or  
proportion <0.25 for Western Hunter-gatherer ancestry.
Reporting summary
Further information on research design is available in the Nature Port-
folio Reporting Summary linked to this article.
Data availability
All aDNA data used in this study were publicly available, and accession 
codes are listed in Supplementary Table 1.
Code availability
Twigstats is freely available under an MIT licence through GitHub 
(https://github.com/leospeidel/twigstats), and detailed documenta-
tion, as well as example data, is available at https://leospeidel.github.
io/twigstats/. The code has also been deposited at Zenodo (https://
zenodo.org/records/13833120)76. All scripts to reproduce simulations, 
and to run Relate on imputed ancient genomes, and downstream 
analyses, including computation of f-statistics and running qpAdm 
models, are available through GitHub (https://github.com/leospeidel/ 
twigstats_paper).
 
70. Maier, R., Flegontov, P., Flegontova, O., Changmai, P. & Reich, D. On the limits of fitting 
complex models of population history to f-statistics. eLife 12, e85492 (2023).
71. Kelleher, J., Etheridge, A. M. & McVean, G. Efficient coalescent simulation and 
genealogical analysis for large sample sizes. PLoS Comput. Biol. 12, e1004842  
(2016).
72. da Mota, B. S. et al. Imputation of ancient human genomes. Nat. Commun. 14, 3660 
(2023).
73. Rubinacci, S., Ribeiro, D. M., Hofmeister, R. & Delaneau, O. Efficient phasing and imputation 
of low-coverage sequencing data using large reference panels. Nat. Genet. 53, 120–126