Notes & Tones · An interactive essay

The Genetics
of Unicorns

Nature or nurture? Even in a fairy-tale world with the simplest possible genetics, the answer keeps slipping through our fingers. Here's why, with sliders you can drag and numbers you can break.

Scroll to begin ↓

"Was I born this way, or did I become who I am because of what happened to me?" "Can anyone get good at maths, or should we save our effort for those with natural talent?" "Are these people more likely to end up in prison because they're inclined to it, or because of how we've arranged society?"

We tend to frame these as nature versus nurture, and we tend to assume the questions have answers, if only we had sharper tools or a big enough dataset.

This essay makes an awkward case: that even in the most unrealistically simple worlds we can invent, these questions only have answers that hold for one specific time and place. The results don't generalise, and at the very least they need to be read with care. To show it, we'll breed some unicorns.

01 It's in our genes

You wouldn't guess it from some newspapers, but genetics is a technical subject. Here's the whistle-stop version. There are good primers online if you want more, like this one.

We're built from cells, and what a cell does is encoded in long molecules called DNA. Inside the cell, DNA is packed into bundles called chromosomes; humans carry 23 pairs. Along those molecules sit genes, units of code each with a job to do. We inherit two copies of every gene, one from each parent. That is why chromosomes come in pairs, and it doubles as a handy backup, because if one copy is faulty the other can often cover for it.

As the generations roll on, genes mutate at random. Viable mutations get passed down, and over time a single gene can accumulate several variants that do subtly, or dramatically, different things. These variants are called alleles. A gene for eye colour might have one allele for brown, another for blue, and so on. As a rule of thumb, the more critical a gene's job, the fewer alleles a species can afford to carry.

Genes also interact. How an allele is expressed depends on the allele it's paired with, on the other genes nearby, and on the environment the organism grows up in. The simplest kind of interaction is an allele that only shows itself when paired with a copy of itself. We call that recessive. An allele that shows up whether paired with itself or a different variant is dominant.

We'll run two experiments. First we'll try to apportion the effect of two competing alleles in a population. Then we'll try to split a trait's variation between genes and environment. Both look like the sort of clean measurement science should be able to deliver. Both turn out to be tied to a particular place and time.

02 The relative effects of alleles

Take the simplest possible trait: one that's either present or absent. Unicorns are perfect. As is well known, a horn in the middle of the forehead requires two copies of the recessive a allele. The dominant variant, A, suppresses horn growth. So an aa individual is a unicorn; aA and AA are just ponies.

Now ask: how much does each allele contribute to unicorn-ness across the population? It's a fair question, but the answer isn't fixed. It depends entirely on how common each allele is. With a couple of standard assumptions and the Hardy–Weinberg equation, if a and A are equally common the population settles into 25% unicorns and 75% ponies.

Drag the slider below. Let q be the frequency of the recessive a, so the frequency of A is p = 1 − q. Watch what happens to the proportion of unicorns, and to how much "credit" each allele gets for the trait.

q = 0.50 p = 0.50
25%
of the herd are unicorns
ponies (AA) 25% ponies (aA) 50% unicorns (aa) 25%
"Effect" of a
+25%
"Effect" of A
−25%
At q = 0.50 the two alleles look equally powerful. Slide towards the extremes and that symmetry collapses.

At q = 0.5 the two alleles look evenly matched: a gets +25%, A gets −25%. We might be tempted to conclude that a is "the horn allele" and leave it there.

But nudge the frequencies. Set p = 90% and q = 10% and the same arithmetic hands back −9% for A and just +1% for a. That is a completely different story about the same two alleles.

So although each allele's effect on an individual is crisp (you either have a horn or you don't), its effect on the population is a fingerprint of its frequency. Measure an allele's "importance" in one population and you'll get a different number in a population where it's rarer or more common. The measurement is legitimate; it just isn't portable. Worth remembering the next time someone talks about the "inherent" qualities of one group versus another.

03 Genes versus environment

The same trap is waiting when we try to divide a trait between genes and environment.

Use an equally cartoonish model. One gene, two alleles, b and B, this time setting a measurable trait: the length of a unicorn's horn. Keep them equally frequent (p = q = ½), so by Hardy–Weinberg the herd is 25% bb, 50% bB, and 25% BB.

Now let our unicorns live in two habitats, woodland and cloud forest, split evenly between them. We measure horn length, in centimetres, for every genotype in every habitat. The table below is live: edit any number and the whole analysis recomputes. It starts on a real, awkward dataset.

Try:
Horn length (cm)WoodlandCloud forestgenotype avg
bb 85
bB 115
BB 85
habitat avg 110 90 100

Where does the total variation in horn length come from? The analysis of variance splits it into three buckets:

Genes b/B
30%
Habitat
13%
Interaction
57%
Total variance 750 cm²  ·  genes 225  ·  habitat 100  ·  interaction 425. The interaction term is large, so genes and habitat can't be cleanly separated here.

Look at the starting numbers. In woodland the longest horns belong to the heterozygous bB unicorns; in cloud forest, horn length just climbs with every B. That flip is not exotic. It mirrors how certain haemoglobin variants help or hurt depending on whether malaria is around.

Now the tempting mistake. Since every woodland unicorn shares one habitat, any spread within woodland must be down to genes, and likewise within cloud forest. Average those two within-habitat variances and you get 650 cm², a full 87% of the total. Conclusion: genes dominate.

But now compute the variance between the three genotype averages instead. It comes to just 225 cm², or 30% of the total. Conclusion: habitat dominates. We've derived the exact opposite result from the same table.

The flaw is that you can't simply add variances like this, because genes and habitat interact. Switch to the "clean, additive world" preset above: there, woodland adds a flat +20 cm to every genotype and the heterozygote sits a fixed distance from the others. The interaction bar drops to zero, and only then do the genetic and environmental shares add up to the whole. In our original, messy table the honest decomposition is:

That fat interaction term does the real damage. It is what stops us carrying these percentages anywhere else. Change how common b and B are, or shift the balance of woodland to cloud forest, and the interactions rearrange themselves and every number moves. We can apportion genes and environment, but the answer is always stapled to a particular place and a particular moment, and it dissolves the instant the situation changes.

04 So what?

Both experiments used the friendliest genetics imaginable: one or two genes, two alleles, a tidy environment, no measurement error. And both still refused to give us a portable answer. The effect of an allele depended on how common it was; the split between genes and environment depended on an interaction term we're not allowed to ignore.

Real traits, things like intelligence, temperament and health, whatever we actually argue about, are built from thousands of genes, tangled with each other and with environments we can't hold still. If the toys already resist a clean nature-versus-nurture verdict, the real thing resists it far more.

The point is not that these questions are unanswerable. Their answers are simply local. Ask them somewhere else, of someone else, and expect a different reply.