What is qpAdm? Admixture modeling with f4-statistics, explained
qpAdm tests whether a population is a mixture of chosen sources and estimates the proportions. How it works, what it needs, and where it fails.
Updated 4 min read
qpAdm is a statistical test of an admixture model. You name a target population, two or more source populations and a set of reference populations. qpAdm then asks one question: is the target consistent with being a mixture of these sources, and nothing else, as seen from the references? If it is, qpAdm also estimates how much ancestry comes from each source, with a standard error.
qpAdm is part of ADMIXTOOLS, the software package from David Reich's laboratory. It was first used at scale in Haak et al. 2015, the study that showed a large migration from the Pontic–Caspian steppe into Europe about 5,000 years ago. Today it is the standard tool for ancestry proportions in ancient DNA papers.
The three lists in a qpAdm model
Every qpAdm model has three parts:
- Target: the population (or the one genome) you want to explain, for example
English. - Sources (the "left" populations): the populations you propose as its ancestors, for example
Luxembourg_Loschbour_Mesolithic(western hunter-gatherers),Turkey_N(Anatolian farmers) andRussia_Samara_EBA_Yamnaya(steppe herders). - Right populations (also called references or outgroups): populations that are related in different ways to the sources, for example
Mbuti,Russia_UstIshim_IUP,Russia_Malta_UP,Iran_GanjDareh_N,Israel_NatufianandHan.
The right populations are not ancestors of the target. They are a fixed panel of "viewpoints". qpAdm compares how the target and the sources relate to each of them.
How qpAdm works
qpAdm is built on f4-statistics. An f4-statistic measures whether two pairs of populations share genetic drift. For a model with sources S1, S2 and S3, qpAdm computes statistics of the form f4(Target, S1; R0, Ri) and f4(Sj, S1; R0, Ri) for every right population Ri, against a base right population R0.
If the target really is a mixture of the sources, then every f4-statistic of the target is the same weighted sum of the sources' f4-statistics. The weights are the ancestry proportions. In linear-algebra terms, the matrix of f4-statistics has a lower rank than it would have if the target had extra ancestry. qpAdm fits the weights and tests that rank with a chi-squared test. The test uses a block jackknife over the genome, so linked SNPs do not make the result look more certain than it is.
The output has three parts:
- A p-value for the whole model. A low p-value (below 0.05 or 0.01, by convention) rejects the model: the sources leave something unexplained.
- Weights, one per source, which sum to 1.
- Standard errors for the weights, from the jackknife.
How to read qpAdm results explains each of these in detail.
What a qpAdm model can and cannot tell you
A model that is not rejected is consistent with the data. It is not proof. Several different source sets can fit the same target, especially when the right populations cannot tell the sources apart. That is why careful studies:
- test competing models and report which ones are rejected;
- rotate populations between the source list and the right list, so that each candidate source is also tested as a reference;
- check that the weights are between 0 and 1 and have small standard errors.
qpAdm also assumes that no right population received gene flow from the target, or from a population close to it, after the admixture. If one did, the model can fit for the wrong reason. Choosing right populations covers this in detail.
qpAdm compared with other methods
- qpWave uses the same machinery but asks a simpler question: how many streams of ancestry link one set of populations to another? qpAdm is qpWave with a target and weights.
- PCA shows where genomes sit in a summary of variation. It is fast and visual, but a position on a PCA plot is not an ancestry proportion.
- G25 and nMonte fit a target as a mixture of points in PCA space. They are quick to explore with, but they give no test of fit.
- qpGraph fits a whole admixture graph, many populations at once, to all f-statistics.
Running qpAdm
ADMIXTOOLS is command-line software, and ADMIXTOOLS 2 is an R package. Both need the reference data in EIGENSTRAT or PLINK format. A run needs the Allen Ancient DNA Resource or another curated dataset, and a merge of your own data if you want to model yourself.
Nexju runs qpAdm in the browser on the AADR. You pick the target, sources and right populations from the AADR's population labels, or you use a genome you uploaded from 23andMe, AncestryDNA or MyHeritage. Nexju can also rotate sources for you, one slot at a time or exhaustively. The free plan includes single qpAdm models.
References
- Haak W. et al. 2015. Massive migration from the steppe was a source for Indo-European languages in Europe. Nature 522. doi:10.1038/nature14317
- Patterson N. et al. 2012. Ancient admixture in human history. Genetics 192. doi:10.1534/genetics.112.145037
- Harney É. et al. 2021. Assessing the performance of qpAdm: a statistical tool for studying population admixture. Genetics 217. doi:10.1093/genetics/iyaa045
- Maier R. et al. 2023. On the limits of fitting complex models of population history to f-statistics. eLife 12. doi:10.7554/eLife.85492