Why no one should be called 007

The internet exploded in outrage when it was suggested that a Black woman might inherit James Bond’s spy code number 007. But really it’s outrageous that anyone gave agents numbers in the first place – not because numbering humans is dehumanising, but because it gives away information.

To understand why it’s bad to number your spies, consider a real statistics problem that the British solved in WWII, known as the German Tank problem. Germans put serial numbers on the gearboxes and wheels of their Panzer tanks, numbered sequentially. The Germans weren’t stupid enough to start at 1, but even so, if you capture three tanks numbered 1011, 1025 and 1037 in different places, you can quickly guess that they started counting at about 1000, particularly if you have multiple numbered items. You can then use this to estimate how many tanks the Germans have made in total and, if you can guess the age of the tanks or keep capturing new tanks, how fast they’re making them. British statisticians used the serial numbers to estimate the total number of tanks Germany was producing, and their estimates were far more accurate than those of the undercover spies that Bond was inspired by.

Using similar maths, if you only know of 007, you can be fairly confident that MI6 had at least six other spies with a similar status (supposedly the 00 numbers indicate a licence to kill). You can have a good guess that they have a few more, since it’s unlikely that you’d only find the highest number – you probably found one in the middle, so expect about the double of 7 in total, although you’ll get better estimate if you catch a few more spies. The formula for the best estimator is usually written as nspies = H*(1+1/ncaught) – 1 for H the highest number seen and ncaught the number of spies caught. There is a 0011 agent in the original books and 0013 is the highest number mentioned in any official media, so this estimate (nspies = 7 * 2 – 1 = 13) seems to be exactly right in our case.

Would this information be useful during a war? Yes. During WWII, the British had no way of knowing the total number of German spies. As a result, it produced enormous amounts of propaganda to keep their population from telling military secrets, resulting in what Churchill called “spy mania” – huge investments in secrecy and personal paranoia, most famously seen in the “walls have ears” posters. As far as any records indicate, the Nazis only ever had about twenty spies in the UK, and all of them were quite rapidly discovered and used to feed misinformation. We could have saved a lot of effort if the Germans had numbered their spies too to give us this order-of-magnitude indication of the risk. Ironically, the counterintelligence committee that fed this information was called the Twenty Committee, but this is because they dealt with double-crossers, and in Latin numerals XX is twenty – an example of a numerical codename that doesn’t give information about the size of the organisation. Historically, the British secret services tended to choose code names based on simple abbreviations and puns on the agent’s actual name, which didn’t reveal anything about the total number of spies but does indicate who they might be, which somewhat defeats the point of a secret name.

In No Time to Die, the 007 title has changed hands. Reusing numbers has both advantages and disadvantages, and will primarily confuse everyone. On the one hand, it means the enemy can no longer use your number to estimate how long you’ve been active in the field unless they know when the previous 007 retired (or was “retired”). If MI6 numbers spies sequentially and another agency captures them over some period of time, they can see how the distribution of numbers they get changes over time to guess how often new spies are licenced to kill, although the maths for guessing how many are alive at any given time becomes more complicated than the tank example above indicates.

But reusing numbers makes the paperwork of following up on old agents exceedingly complicated. MI6 should want to keep track of whether their agents suddenly start living in a country where they had secret dealings. Do the old 007s get another code name upon retirement? And the person promoted – presumably they’re already an agent with some training before they get a 00 number. Do they have an old number or codename? Does someone else fill that in too? Anyone dealing with an agent now needs to know all their numbers and when they were inherited to keep straight where they’ve already been, using what aliases and what they already know, otherwise their secret identities won’t last long.

Finally, if a data file such as a csv with names like this is ever opened in excel and saved, the leading zeros will automatically disappear. Databases will then fail to connect the numbers with the original codename, and any sloppy programming will result in bugs. We can forgive this problem in the books as Ian Flemming died before the invention of Excel and widespread use of electronic databases but a more modern Bond should be aware of these developments (as well as, say, feminism). A less cool but more mathematically responsible MI6 could thwart all these spy-counting problems by assigning agents unique random numbers with several digits, perhaps with a specified digit in front to make it easy to tell who has a licence to kill (any digit except 0 will work). But honestly, the real hero of any Bond story is whoever manages his paperwork.

Advertisement

Inoculation

I evolved today. Received
A splinter of gentle doom.
Began permuting memories
To find the wisest scars.

The rivers of my body tingle,
Anticipating worse and better days.

About the poem

I’ve always loved the idea that evolution doesn’t just happen between generations, but over the course of our lives. Our immune system is one of the most clear and explicit forms of this. We need to make antibodies (things to stick to chemicals our body thinks comes from germs, called antigens) that counter the exact threats we discover, but we aren’t born with them. Germs can churn out new, mutated generations every few minutes, so there’s no point waiting several human generations for normal evolution to save us!

Instead, we have to actively promote the mutation of the B-cells that make the antibodies and find out which ones work best. The ones that are best at sticking to the antigens in the body then clone themselves with more mutations in antibody-making parts of their genes, to get a better fit again. Unlike the ideal form of natural selection though, some of the “failures” are often kept around for a while in case they match a later evolution of the same threat. Your body actively values diversity in its immune response. Otherwise it would hyperspecialise in solving the current problem but have less ability to react to new ones (this is basically the same reason why eugenics doesn’t work).

None of these mutations will be passed onto our children, who will have to start evolving their immune system from scratch. The different sorts of vaccines all work by presenting our body with a fake threat, something it will recognise as a germ but that won’t replicate in our body. Because it looks threatening, our body makes a real immune response to it (occasionally including sickness symptoms, though I didn’t experience that) and starts the process of adapting to fight a new enemy.

https://www.scientificamerican.com/article/your-immune-system-evolves-to-fight-coronavirus-variants/

Poetry and information theory

I did a talk on poetry and information theory for Nerd Nite, discussing how poetry works in different languages, how rapidly people speak in different languages and why this affects how we can communicate, with a few poems containing different amounts of information. You can watch it here:

https://www.youtube.com/watch?v=vOwshTSZfJU

In it I read the poem The Human Virus, which you can read here: https://www.consilience-journal.com/issue-3-the-human-virus

Hummingbird cake recipe

A beautiful fruity vegan cake recipe. Strongly based on the recipe here, but with cheaper ingredients and no icing: https://www.onegreenplanet.org/vegan-recipe/hummingbird-cake/

Ingredients (in order of use):

1 1/2 cups all-purpose flour
1 cup sugar
1 1/2 teaspoon baking soda
1 teaspoon baking powder
1/2 teaspoon salt
1 teaspoon ground cinnamon
1 cup mashed bananas
1/4 cup virgin coconut oil (melted)
1 tablespoon pure vanilla extract
1 tin pineapple, chopped (separate the juice)
1/3 cup chopped nuts or desiccated coconut
Flaked almonds, to decorate
Optional other decorations, e.g. glace rose petals, physallis, redcurrents

Recipe:

  1. Preheat oven to 180C. Grease a pan, at least 8 inches/20 cm diameter (larger will be flatter but quicker to cook).
  2. Combine the dry ingredients (the first 6) in a bowl.
  3. In a separate bowl, mash the bananas with the pineapple juice. Pour in the coconut oil and vanilla extract.
  4. Chop the pineapple into smallish chunks and add to the wet ingredients with the chopped nuts or coconut.
  5. Stir the dry ingredients into the wet ingredients.
  6. Pour into the pan and scatter the flaked almonds on top
  7. Bake for over 25 minutes (depending on how deep the pan is). Three tests to see if it is ready: it will be a fairly deep brown, smell wonderful, not wobble at all when shaken and a toothpick poked through the middle will be at least mostly clean.
  8. When it is cool, add any decorative fruit. If you want to glace any rose petals or redcurrents, brush or dip them in aqua faba (leftover juice from a can of chickpeas) and scatter sugar over them (both sides) while they are still wet. You can dry them in a barely-warm oven to speed up the drying, although if you place them on the cake before completely dry they will stick in place better (rose petals will dehydrate a little if you heat them in this way).

We’ve always called vegan food by meaty names

The EU is considering legislating on the use of “veggie burger” and “veggie sausage” as ways of describing vegetarian meat-substitutes, and has previously banned using “soy milk” and “vegan cheese” as descriptors for vegan substitutes. But these terms are widely understood and have a well-established history.  

Using “milk” to describe milky plant products dates back to the 13th century. Since red meat and dairy products were forbidden to Catholics during lent, the English aristocracy were passing around recipes for almond milk far before anyone thought of putting it in a flat white. In fact, with the short shelf-life of unrefrigerated dairy milk, almond milk became a mainstay of refined European cooking in all seasons. It appears in fully a quarter of recipes in the oldest surviving German cookbook, Das Buch von guter Speise [the Book of Good Food], from 1350, often combined with lent-defying butter and eggs. Lacking the almond’s exotic appeal, dairy milk appears in less than a tenth of the recipes. 

Although sausages were also eaten in Germany at the time, the word only entered English in the 15th century from French. The word sausage just means “seasoned with salt,” which is just as true of vegetarian sausages as meat ones. People wouldn’t talk about vegetarian sausages until the late 19th century, as “vegetarian” only came to be used in the modern way in the Victorian era. However Glamorgan sausages, made mostly from cheese, bread and leeks, had usually stopped including meat by this point. It’s not clear exactly when this changeover happened. Vegetarian versions were certainly available by the 1850s, but this is a case where EU labelling laws would be useful!  

Using “cheese” to describe fruit cheeses also dates back to the 15th century. Fruit cheeses don’t resemble cheeses to the modern taste – they are essentially an extremely condensed fruit jam or jelly that can be cut with a knife. Famous examples include quince cheese, a paste created by boiling down quince with sugar, or in earlier recipes, honey. It’s sometimes known by its Spanish name, dulce de membrillo. A similar process of refining fruit with more filtration produces a “fruit butter.” Apple butter, for instance, was often made by caramelising apple puree into a smooth preserve, and was widely known to Victorians.  

These products don’t particularly resemble dairy so the name was as uncontroversial as our Milky Way Galaxy (which references milk in both English and Greek, in spite of containing negligibly little dairy). Longstanding legal controversy did exist over products that bore closer resemblance – for a short time after 1884 a US law stated that “No person shall manufacture out of any oleaginous [oily] substance, or any compound of the same, other than that produced from unadulterated milk or of cream… an article designed to take the place of butter or cheese.” However, because this clearly prohibited making any sort of margarine at all, the law was struck down as unconstitutional in 1887. Strong legal prohibitions remained against adding colour to the margarine, a step that could only be justified as trying to make a better imitation of butter. This was considered misleading, even when the product was clearly labelled.  

In terms of misleading, the fact that hamburgers are neither required to come from Hamburg nor actually contain ham is far more confusing than anything vegetarians have ever done to them. Seventh-day Adventist food retailers Loma Linda Foods began selling gluten-burgers in 1938. This predates by a year the first recorded abbreviation of hamburgers to “burgers”. Loma Linda had started selling “soymilk” four years earlier, taking the recipe from the Chinese. The name was not imported – since milk was not widely drunk in China, it’s not as useful analogy and the literal translation of the Chinese name is “bean pulp”. Buddhists in China have however replaced meat with imitation products for around 2000 years, creating an incredible library of products often named after the animal being imitated. Naturally when these products were imported, translations of names like fake duckfake shark fin and fake crab come with it. Meat eaters can still buy crab sticks in America which contain no crab meat (although they need an explanatory subtitle in the EU).  

There’s also a confusing middle ground. When making soymilk, a layer of concentrated soy rises to the top that can be processed to make tofu skin, which has a texture similar to beef jerky. It is often used as a skin layer in more elaborate fake meats, but arguably the name refers to how it originally forms on the surface, in the same way as we talk of a milk skin on boiling milk (although it tastes nothing like skin). And while recent developments have mostly been to veganise meaty terms, the very term “meat” once referred to food of all kinds, before being used as an abbreviation for “flesh-meat”.  

For thousands of years, a huge range of spiritual paths have inspired people to replace animal products in their diets with something else. Over this time, language has evolved through analogy, similarity and mutation to meet the changing needs of a society trying to describe new foods. To seek legislation to divorce vegan food from the way we’ve historically referred to it is a cynical move by the meat lobby to alienise new forms of old food. For the EU to be complicit in this is a mistake of galactic proportions.

Everything wrong with the paper “Human grief: Is its intensity related to the reproductive value of the deceased?”

Have you ever read a science paper that’s so statistically invalid, logically flawed and offensively awful that it accidentally becomes So Bad It’s Good? Here’s a review of a paper from the depths of 1980’s Evolutionary Psychology. There will be a lot of insensitive discussion of dead children, plus most forms of bigotry. It will not feature necrophilia, in case the title is misleading for anyone. If you think I’m exaggerating its faults, you can read it yourself here: https://sci-hub.tw/10.1016/0162-3095(89)90006-x

I was directed towards this paper by a blog post titled “An Especially Elegant Evpsych Experiment”. The writer of the blog concedes he did not read the paper, which is the only possible explanation for its title. The paper itself is titled “Human grief: Is its intensity related to the reproductive value of the deceased?” The basic premise of the paper is parents are more sad about losing children if those children were likely to have children of their own in the future if they were hunter-gatherers. They will establish this by questioning people who have never been either hunter-gatherers or bereft of children (as far as we know) and then over-analysing the results. I could criticise this experimental design for not asking real bereaved parents, but given how insensitive the authors are, that’s probably for the best. I don’t merely mean their language is clinical: they go out of their way to reference touchy topics while glossing over important technical details. The introduction summarises results from other work with phrases like “healthy male [child] > healthy female = unhealthy female = unhealthy male for intensity of grief [by parents]”. The use of these mathematical symbols when assigning value to deaths is so callous and uncaring: obviously they should have used the ‘approximately equals’ signs. Incidentally, this is result is not consistent with the paper’s thesis. You’re supposed to think that, since males have a wider range of number of children, their health matters more to parents. However, given the whole one-sperm-one-egg thing, the average number of children born to males and females should be very similar*. If your metric values healthy males more than healthy females, unhealthy males have to be valued less than unhealthy females to make up for it. Otherwise you’re just spouting Darwin-flavoured sexism.

The introduction also says that a proposed correlation between grief of loss and child age in a previous paper was wrong. So these authors are trying with reproductive fitness instead. Which, at least in this paper, is just a function of age and sex (while they flirt with ableism, they don’t really want to commit to it. Even though infertility would have been a stronger and faster test of the main thesis). So they could have avoided all this work if they just got the numbers from a previous paper and applied one function to the results before doing the same stats.

They then introduce the concept of ‘reproductive value’ (RV): “Fisher’s (1930) concept of reproductive value provides a measure of those factors related to the age of both the offspring and the parent. It is the relative number of offspring still to be born to an individual of age X.” There are technical respects in which this definition is wrong (RV is normally corrected for population growth), but let’s focus on why it’s a terrible metric to use in our case. It explicitly ignores the importance of nurturing existing children and only focuses on unborn children. Once you’ve had a child, your RV actually reduces because you’re going to invest in bringing up that child, whereas your expected number of grandchildren/later descendants increases. While there are other, better ways to define RVs that value parental nurture, this study isn’t using them. Which, for a study about the grief of parents losing children, is a pretty big problem.

They end the introduction by including a graph showing RVs (as defined here) for various human populations, and how it changes over time in Japan and between black and white South Africans. It’s reproduced from another study, and wouldn’t be relevant here if they’d properly explained what RV was. They specifically instruct us to “Note the differences between the curves for black and white South Africans and for Japan for 1964 and 1966. These figures suggest that reproductive value is a measure that may capture at least some of the cues that may regulate the intensity of parental grief over the death of offspring.” However this figure (there is only one) doesn’t capture anything about parental grief, and I have no idea why they think it does. It literally just shows a measure of population dynamics. Race doesn’t otherwise appear in this study at all – it seems to be included here to get another tick on the edgelord checklist (I notice that the lead author has literally won a ‘Prize in Support of Controversy’). The whole hypothesis of this paper specifically relies on humans not evolving since whenever we were all hunter-gatherers, so we wouldn’t expect to see any differences in grief between societies or races, irrespective of these curves. Quite why Japan changed so much in 2 years is also beyond me – perhaps some sort of baby boom/war effect, but it’s utterly unexplored, and quite possibly it just shows the huge error in measurements. As well as being useless, the graph is physically painful to read, as it relies on slightly different dashing patterns that don’t scan very well, between very similar trend lines.

They round it off by claiming that because females have higher minimal investment (i.e. giving birth is hard), “female parents can be expected to be more sensitive to the reproductive value of their offspring than male parents.” This isn’t true if both parents have to care for the child equally; the mother has already made this minimal investment by the time the child is born, so it’s a sunk cost fallacy. Also, given that you’re reading a study about parental grief, and they break everything down by gender, you might assume that they’re going to statistically test this hypothesis later. You’d be wrong. They don’t really do statistical tests here, they just calculate correlations and then comment on whether they think this number is high or not. It seems they missed the ‘correlation does not imply causation’ part of statistics. I do genuinely congratulate them for including this hypothesis at all though, since they later admit that their weird analysis of the data doesn’t support it. Many studies would have just found some reason for thinking that they expect different patterns.

If you want to see loads of spurious correlations that haven’t been explained using EvPsych, go to https://tylervigen.com/spurious-correlations. This one gets to 96%!

So finally, the actual data collection. They ask lots of test subjects, if two Canadian children of different ages (1 day – 50 years) but the same gender are killed in a car crash, which ones are the parents more concerned about? “Both the same” is not an option, and there’s no relative weighting, just a rank. They have 436 test subjects, which sounds a lot. However the paper splits up the test subjects by their gender (2 options) and their age band (3 options), and each will only be asked about children of one gender (2 options). Some of these categories have 15 in, some have 50. They do not care if the subjects actually have children, which you’d think would matter a lot. They need pairwise comparisons of car crashes with many combinations of 10 ages of children. They also mention in passing that, bizarrely, many test subjects found the questions disturbing, so didn’t complete the survey! I also think it’s uncommon to have families where one child is 50 and one 1 day old, and wonder if the subjects are accounting for the implied age of the parents (the introduction suggests that this matters but it never comes up again). They repeatedly state that requiring so much data means we can’t do statistical tests, because there’s too many samples needed to construct one line. What they mean to say is that in spite of having so many test subjects, their way of generating the normalised grief curves is so inefficient that the statistical tests have nothing to run on. This is the sort of thing you should maybe check when designing your experiment. If they’d asked all these people the same handful of questions, they could do normal tests.

They then calculate an implied ‘relative grief’ statistic in each case, and calculate the correlation between this and age (low), this and RV (medium) and this and the RV of female !Kung bushpeople (very high). If you’re wondering where that last one came from, so am I. It’s implicitly because !Kung are supposed to be culturally like ancestral hunter-gatherers, although no evidence is presented for this. You can tell that’s not true from reading their name: they’ve clearly made linguistic inventions most humans haven’t (the ‘!’  stands for one of many click sounds). Even if !Kung technological culture was identical to early human culture, and cultures and death rates didn’t depend on local geography, they would still experience spill-over effects from diseases, mosquito populations and land-use changes in the areas around them. RVs (properly defined) are supposed to depend on general population growth and are very sensitive to changes in infant mortality. If you’re on the lookout for more cognitive biases, you’ll be pleased to note that the study would explicitly prefer to use both female and male RVs, but couldn’t find it for males, so will assume it’s the same. Availability bias FTW! I wouldn’t normally care, but they spent half the paper banging on about how different the sexes are. They later find that the correlations are slightly higher between female !Kung RVs and the grief response for male Canadian children than for female Canadians, which should be a bit awkward for their theory, but is unremarked on. They do not consider other simple correlations, like mortality rate, which should look fairly similar to the !Kung RVs.

I indicated that the correlations are calculated for loads of groups, but there seems to be little systematic impact of the gender or the age of the assessor. Not to worry, they also calculate mean values. I have no idea how. Most of the values I can reproduce by averaging those numbers. Linearly averaging them. Like, using the 3 reported numbers without weighting for how many test subjects are in each category. This is basically looking for Simpson’s paradoxes. However the !Kung correlations that are so impressively high don’t follow this pattern, and the mean values can and do exceed the constituent values. This implies some sort of pooling action before calculating the values, which is the correct thing to do but is not described. The numbers they get look OK from the graph they show, but I’m not sure how they combine their results to get that graph.

They start the discussion by congratulating themselves for correctly predicting that there’s some correlation between some metric of RV and grief. Quote: “Thus, the validity of this study depends on the assumption that the subjects empathized with the situations described in the questionnaire. The variation in the correlations between grief and reproductive value for the different conditions suggests that it holds for this study.” I.e., we see different numbers and we got an answer we liked, so the premises are valid. They then acknowledge they were wrong about the male/female subject divide, and fumble around with the idea that there might be some weird patterns whereby estimates correlate better for male children than female children, but this is clearly post-hoc reasoned. They then consider random alternative hypotheses to the grief = RV, but not the most obvious hypothesis, that grief correlates with probability of dying, i.e. unexpectedness, which ancestrally obeys a similar curve (high mortality near birth and after 40), and would be the null hypothesis if I ran the experiment.

OK, so we know that correlation doesn’t imply causation, but should we at least be impressed by the high correlation they somehow calculate? No. Here’s another major stats fail. It’s a time series. Time series usually correlate with themselves. You can’t do normal correlation analysis on timeseries unless the values change so rapidly that the value at one time is totally unrelated to the value at neighbouring times. If the values change slowly, you can make a guess that data at a later point is about what it was before plus how fast it was changing. So if you compare two timeseries and the first two points line up, they’ll probably be similar at the next point too. This is why all the spurious correlations you can find at https://tylervigen.com/spurious-correlations are timeseries – the graphs nominally have 10 points, but the points aren’t truly independent. I’m not saying the high correlation values in the study are pure chance – the RV and grief timeseries both have a rising, a level and a falling bit – but this is nowhere near as impressive as if the high correlations came from a genuine scatter plot of independent points. There are ways around this problem – detrending the data, i.e looking only at derivatives that don’t correlate to themselves. This paper does not do them. Hence, even ignoring alternative explanations, its headline result is worthless.

In conclusion, evolutionary psychologists have a bad name for simplistic handling of complex and emotionally charged topics, ignoring the role of society in determining behaviour and drawing grandiose conclusions from an imaginary human history. This paper justifies all of these stereotypes and adds to the mix “can’t do stats”.

* Similar but not identical, since there can be (and usually are) slightly different numbers of males and females in the population at any given age. In general more male children are conceived, but more females make it to puberty. This paper is in no way ready for the subtlety of this consideration, or of the biological ambiguity inherent in the idea of binary sex. Let’s get them up to GCSE science first.

Air Pollution under lockdown

Our paper about lockdown emissions is out now, you can read it here:

https://www.nature.com/articles/s41558-020-0883-0

or read about it here:

https://www.bbc.co.uk/news/science-environment-53681096

Although lockdown won’t have much by way of short or long-term impact on temperature, it does impact air quality in the short term, providing health benefits (not as substantial as the health problems that lead to the lockdown though…). Here’s an animation of SO2 (unlike the NOx plot above, this is not significantly affected by airplane emissions). These plots use the methods in the paper but apply the sectoral changes to more detailed, gridded data.