Lies, damned lies, and income distributions.

It’s been a while since I fired up the old blog machine, but this morning I came across an article so spectacularly misleading that I felt compelled.

The link showed up in my Facebook feed with the preview line “America’s poorest are about as rich as India’s richest”, which the author repeats again in the middle of the article.

The author is commenting on a feature of a graph contained in the article, which is that the top 5% of the Indian population clock in at the world’s 68th percentile for income (after adjustment for local purchasing power), as do the bottom 5% of Americans.

What isn’t stated explicitly is that those groups are composed of 50 million and 15 million people, respectively, and that the average income in each group (which is what the points in the graph are based on) is a basically meaningless number.

The first reason for this is that comparing income in purchasing power parity across very different economies doesn’t necessarily yield useful information, since it means very different things to be unable to afford different goods in different places. If you can’t afford a car in Kuala Lumpur, that doesn’t really matter, since you have a great public transport system available to get you to work – if you can’t afford a car in rural Queensland, you’re in deep shit.

The second reason, and the one that renders the leading line of the article so staggeringly wrong, is statistical. The statement that America’s poorest are as rich as India’s richest should be obviously wrong to anybody who knows anything at all about poverty in the U.S. or wealth in India. The richest people in India own companies, mansions, and BMWs, just like the richest people everywhere. The poorest people in America are either bankrupt or have debts greater than their assets (regardless of their income). And, as an aside, for this reason it doesn’t even make sense to equate “income” and “poverty”, really – one person might have a small income but own their own home, or while someone else might have both a high income and huge debts, and be living paycheque to paycheque. “Poverty” isn’t the same as “low income”.

But on top of that, even if it did make sense – because of the way income is distributed, the top and bottom 5% of the income distributions of any country contain huge, huge discrepancies in income within them. The Americans at the very bottom of the income scale aren’t just a little bit worse off than the people at the 4.5% mark – they are catastrophically worse off. Likewise, the top 0.5% of Indian society (about 6 million people) aren’t making a little bit more money than the people at the 95.5% mark – they are making orders of magnitude more.

Because India and the US have pretty high wealth inequality and very large populations, and because of this quirk of income distributions at the extremes, talking about the mean incomes of the top and bottom 5% of the population in each country is both economically and statistically meaningless.


The graphs above show the kind of shape that each end of the income distributions would have in each country (based on my knowledge of income distributions, not actual values – the values on the y axis don’t represent anything real). These two graphs have the same mean value – but it would be absolutely absurd to say the people on the far left of the US graph are as well off as the people on the far right of the Indian graph – you can see very clearly that that isn’t true. Means are only informative when they’re used to describe data that sit on a bell curve. I hope anybody reading this, even if they’re not into statistics, is able to see that those graphs are not bell curves. The average income of each group doesn’t tell you anything.

To give another example, it might be the case that the shortest quarter of men have the same mean height as the tallest quarter of women, but it would be absolutely ludicrous for me to use that fact as the basis for a statement that “the shortest men are as tall as the tallest women”. That’s obviously not true, because the mean height I’m using doesn’t actually give us any information about people at either extreme. That’s not what means do – they tell you about the middle of a bell curve, not its ends.

There are only two broader interpretations of the statement “America’s poorest are about as rich as India’s richest” that I can see – either India is a place of such misery that even it’s richest citizens live like the worst-off characters in The Wire, or the American poor are so fantastically well off that they live as well Bollywood’s biggest stars, and they ought to think themselves lucky. Both are simultaneously laughable and offensive, and I’m genuinely disappointed that this one got through to the keeper at a progressive news website.

Posted in Uncategorized | Leave a comment

How I got out of iMessage purgatory (iOS 9.2.1 problem)

This isn’t normally a tech blog, and I’m not a tech person, but this seems to be an unsolvable problem for some folks, so here’s how I solved it.

The problem: Texts from iMessage disappear when texting some contacts. I recently bought an iPhone, and today I was texting a friend who also has an iPhone, but who had iMessage switched off. My texts looked like they were being delivered, and they were… to his iMac, in his house, but not to his phone in his pocket.

The problem seems to be that if someone uses iMessage to text someone who used to have iMessage but has it switched off on their phone (or has switched to Android), Apple wants to send the texts as iMessages, not as SMS’s. And off they go, sometimes to an iMessage account that is no longer active on any devices at all. If two people both have iMessage switched on, no problems – if they both have it switched off, also no problems. But one off, one on – texts get stuck in purgatory, with no error message alerting the sender that they’ve gotten lost.

I tried most of the fixes listed online, and eventually went for a complete nuke-it-from-orbit approach, which fixed it. This consisted of the following:

  1. Totally remove my Apple ID from iCloud and all associated apps on my laptop – not just log out / disable the account on Messages, this wasn’t enough. Remove. Obliterate. (Possibly overkill? Not sure.)

    Settings > iCloud > Sign Out > Delete From Mac (and yes to all “Delete X from Mac” queries.

  2. Also delete my Apple ID from Messages on my phone, and then turn iMessage off.

    Settings > Messages > Send and Receive > Apple ID > Sign Out

    back to Settings > Messages > then toggle iMessage off

  3. Deregister my Apple ID from iMessage at the following link, using the text message feature under “No longer have your phone” (not just turning iMessage and FaceTime off like it says at the top):

And lo, I can now both send and receive texts with other iPhone users, whether or not they have iMessage turned on or off. Magical!

This seems ridiculous, but it does seem to be the only way to ensure that you can both text other people *and receive texts*. Simply turning iMessage off worked fine for texting my friend, since then we both had it switched off and we were both trading SMS’s. But that put me in purgatory with him – when another friend with iMessage turned on tried to text *me* after I’d turned iMessage off on my phone and logged out on my laptop, his own texts went nowhere. So if you leave it on, you can’t talk to people who have it turned off; if you turn it off, people who have it turned on can’t talk to you. Nuke it from orbit seems the only way to ensure full functionality, as far as I can see. Seems mad, but there you go!

(Related: A different friend was having the same problem messaging me, in turned out, because of a similar problem with Signal – I was still registered on my old Android, and when I texted him, his replies were piling up in Signal on my old phone (no notifications), not coming to my iPhone. Simply deregistering from Signal in my Android phone fixed this immediately, though.)


Posted in Uncategorized | Leave a comment

Antibiotic resistance 101

Discussing the recent coverage of increasing drug resistance among gonorrhoea infections made me realise that a lot of people don’t really understand how antibiotic resistance happens or spreads. This is an attempt at a 101-style explainer. I suspect most people already have 90% of the knowledge needed to make sense of this, they just haven’t put it all together yet. I’m going to start with an example from animals which I think will make intuitive sense to people, and then move onto the bugs.

Antibiotic resistance develops through a process of evolution, through natural selection. Most people are familiar with how natural selection works in animals. Our DNA is subject to a constant process of mutation, both during our lives and from one generation to the next. Some of these mutations are harmful, like the BRCA mutations that put women at high risk of breast cancer. Some are beneficial, like the development of the ability the digest lactose that arose in European populations after the domestication of cattle. And some are neutral, like the mutation for red hair, which looks nice but doesn’t really do much for you either way.

Mutations happen at random, but whether they are harmful or helpful determines how effectively they spread through populations. For example, acacia trees, which are common in parts of Africa where giraffes live, are covered in huge thorns, making them a very unattractive food source unless you happen to be a giraffe with a very tough mouth. This doesn’t really matter, provided there are other things to eat if you have a soft mouth. But say there is a terrible drought, and all the easier-to-eat plants die off – suddenly a giraffe with a tough mouth has a big advantage over other giraffes. It’s more likely to survive a drought and have children, and those children will probably also have tough mouths, enabling them to survive and reproduce during droughts in their own lifetimes.

Now, a giraffe with a tough mouth that breeds with a giraffe with a soft mouth may not pass on its tough-mouth gene to its offspring – its partner’s soft-mouth gene might override its tough-mouth gene. Because (most) animals reproduce sexually, which involves mixing the genes of two different animals together, some useful genes get lost between generations. This is not a problem for lifeforms like bacteria that produce asexually. Bacteria don’t need other bacteria to reproduce with – they just split themselves in half, cloning themselves. One bacteria splits in half to form two, they split in half to form four, they split in half to form eight, and so on – all clones of the original, except for any new mutations that occur along the way.

This has a big impact on the survival of useful mutations in bugs. Prior to the discovery of antibiotics in the mid 20th century, bacteria were just going about their business, infecting humans, and being transported from one place to another. My favourite bacteria, the tuberculosis (TB) bug, was being carried around and transmitted by people all over the world.

In the late 1940’s, doctors in the US realised that the antibiotic streptomycin killed TB bugs. Suddenly, being a bug that was immune to streptomycin was the equivalent of being a giraffe with a tough mouth – it meant particular bugs could survive circumstances that were a disaster for everybody else. By the time someone with TB gets to a doctor, their lungs are absolutely chock-full of bugs – millions upon millions of the little blighters. When they start taking streptomycin, all of those bugs get exposed to the antibiotic, and most of them die. But if a few bugs have a random mutation that makes them resistant, those bugs survive and continue multiplying while all the bugs around them die. Eventually, only resistant bugs remain in the person’s lungs, and the person may then cough those bugs onto someone else before the TB kills them.

In this way, antibiotic resistant bugs can spread from person to person, and in the modern age, from country to country. This is what we’re currently seeing with TB, gonorrhoea, and other bacterial diseases. Drugs that came into use provided a strong advantage for bugs that could resist them, and those bugs survived and spread around the world. As newer drugs get introduced in specific places, the bugs infecting the patients on those drugs become resistant to those as well. The streptomycin resistant TB bugs from the 1950s have continued circulating around the world, picking up resistance to more and more antibiotics, and some strains of TB are now resistant to basically all of the drugs we have.

Remember though that bacteria, like humans, are undergoing constant evolution. There are unimaginable squillions of individual TB bacteria around the world, and even though they are all clonal descendants of previous bugs, they are constantly evolving. This is what gives rise to different “strains” of various bacteria – like humans have a variety of lineages. We’re all the same species, but we have different characteristics. Most TB bugs are still vulnerable to all drugs, some are resistant to one or two, and some are resistant to many or all drugs.

When you read that “TB is becoming drug-resistant”, this doesn’t mean that all TB bugs in the world are acquiring resistance to the same drugs at the same time – this would be like if somehow, overnight, everybody in the world became a redhead. Drug resistance, like hair colour, is a characteristic that is mostly passed down from one generation to the next.

However, bacteria have an additional trick up their sleeves that animals like us do not – they can actually swap genetic material with one another within their own lifetimes. Human genes are all contained on chromosomes, and the 46 you’re born with are the ones you’re stuck with – you have 46 identical copies in every cell in your body. Bacteria, however, are a single cell – and they are capable of trading small individual chromosomes (called “plasmids”) with one another. What this means is that not only does one drug resistant bug divide to create two drug resistant clones of itself (who then divide to create four, and so on) – it can also simply give a copy of its drug resistance genes to a friend!

But to give something to a friend, you have to meet the friend in person – bacteria are yet to develop a postal system. Someone with TB will have millions of individual bacteria in their lungs, some clones of one another, some very different. Those bugs that get close enough to touch one another can swap copies of their plasmids, but a bug in my lungs can’t give a plasmid to a bug in yours, unless the bug itself gets transferred over.

So that’s the mechanics of drug resistance in bacteria. Individual bacteria develop a mutation that makes them resistant, and they can pass that mutated gene to their clonal children, and to friends in their immediate environment. But the gene still has to spread through the population basically the same way different characteristics do in humans – mutations for red hair have arisen several times in several different places, but not everybody in the world has red hair. Even if I could make other people into redheads by touching them, the way bacteria can swap genes between friends, I would still have to chase people around and lay hands on them.

Bugs that are resistant to common antibiotics have a big advantage, and we have to make sure we expose them to other drugs that will definitely kill them – for example by treating streptomycin resistant bugs with penicillin, and vice versa. This is difficult, but not impossible. Drug resistance is on the rise and is cause for concern, but bacteria are subject to most of the same genetic laws as the rest of life on earth, and the antibiotic era is not over just yet.

Posted in Uncategorized | Leave a comment

Chicken little and child mortality

A couple of months ago I sat down in the bathroom at a comedy event and looked at a poster promoting the works of a large international charity. The poster was dominated by a photograph of a smiling child, but underneath were the words “In Kenya – where nearly two in every five kids won’t reach their 5th birthdays – clean water and toilets are life-savers”. I can’t claim an encyclopaedic knowledge of under five mortality rates in African nations, but that seemed really, really high. Kenya is actually quite a bit better off economically than a lot of countries in the region – it has less conflict, less poverty and better health services than many of its neighbours. So I did a quick google on my phone and came up with the UNICEF and World Bank figures, which are both freely available online.

According to the World Bank, which uses the same data as other UN Agencies, the estimated under 5 mortality rate in Kenya is 71 deaths per 1,000 live births, which works out to one in 14, a far cry from “nearly two in five”. Kenya is ranked 35th in the world, behind dozens of other African countries and countries that are heavily conflict affected like Afghanistan. Angola leads the world with 167 per 1,000 live births, equivalent to one in six, still far below the charity’s statistic. (For comparison, high income European countries have a rate around 2 per 1,000 or one in five hundred.)

Child mortality

That such a high profile charity made such an astonishingly inaccurate claim bothers me for a number of reasons. Firstly, how on earth did that make it onto a poster? Does the communications team at this charity have so little background in health and so little experience in African countries that nobody thought that sounded a little high? Secondly, what does a claim like this say about the role of data in charity? Does the average Australian who sees that poster believe that Kenya (of all places) is a place of such endless desperation that it seems credible that near enough to every third child born there dies before turning five? If not, are we so used to seeing figures like this thrown around that we don’t even stop to consider what they mean in practical terms? Either way, something is very wrong here, and not with Kenya.

Posted in Uncategorized | 2 Comments

Aspartame and other boogeymen

There is a persistent and common belief that artificial sweeteners and other food additives are “bad for you”. This belief is sometimes very vague, but sometimes in connection with specific concerns such as cancer. Googling “aspartame” and “cancer” unsurprisingly turns up dozens of pseudoscientific, alarmist websites proclaiming its toxicity, and a much smaller number of websites such as those run by the National Cancer Society in the US and the UK’s National Health Service, trying to assure the public that it is safe.

The confusion about aspartame and other specific food additives speaks to a serious problem in both epidemiological research and in scientific journalism. Observational studies in nutrition suffer from a really serious signal-to-noise issue – separating out particular dietary causes of cancer or heart disease among the huge variation in people’s broader diets, exercise habits, family histories and general life conditions is extremely challenging.

The epidemiologists who do this type of research are often appropriately circumspect and carefully state the limitations of their conclusions, but this doesn’t make for exciting headlines. The media jump on particular studies – especially those that report that something may be dangerous – remove all the caveats, and report a completely sensationalised and de-contextualised version of the research findings. And six months later, when another study finds the opposite, the very same newspaper might run a story to the opposite effect. See the coverage of research into the health benefits of chocolate and red wine for an example.


This leaves the general public feeling like the scientific community is either constantly flip-flopping, since the media are perpetually reporting conflicting results about the same foods, or that we have decided something is definitely harmful because the only study that made the papers was the one reporting a link to cancer, while dozens of other studies showing no such association were ignored. In fact, the pace at which national dietary guidelines change is positively glacial, and most experts would be very guarded if you asked whether they thought this or that might be harmful, unless the evidence was absolutely overwhelming. (Most of us will unreservedly advise you not to drink lead paint, for example.)

Aspartame in particular is a frustrating example. Hysterical reporting on a couple of studies seems to have dominated the public perception of it, even though health authorities have been convinced by the weight of evidence that it’s safe for people without serious pre-existing kidney problems. Meanwhile, the additive that aspartame is supposed to replace – sugar – is the subject of far more damning evidence regarding its impact on obesity and type 2 diabetes.

In general, when you see newspaper articles about links between health and specific foods, you should assume they are overstating the case. Common sense – eat less junk food and more vegetables – doesn’t make for sexy headlines, even if that’s really what the public would benefit from hearing.

Posted in Uncategorized | Leave a comment

Multiplying by zero

Last week a friend sent me an a news article saying someone had just discovered that a medication he has been taking for many years “increases the risk of heart attacks”. I related a story to him of how I myself got a slight shock a few years ago, when I read that having had two CT scans of my head as a child tripled my risk of brain cancer.

Beyond relating health risks that neither my friend nor I can do anything about, these two situations have something important in common: the risk of each of the events they increase the risk of, in me and my friend, is negligible. Nothing multiplied by three is still nothing.

As a woman in her late twenties, my risk of brain cancer next year is around 1 in 100,000. Having had those two CT scans, it is now approximately three in 100,000 (or one in 33,000 if you prefer).

Likewise, my friend’s risk of a heart attack or another acute cardiac event as a man in his twenties is around 15 per 100,000 or one in 6,700. The 16% increase that has been estimated from his medication puts him at one in 5,700.

Numbers like these don’t make headlines, and it’s much easier for a paper to report (as they did) that something “increases the risk of heart attack” without providing any figures at all than it is to explain the actual magnitude of the risk with relation to specific groups, such as men under 30.

Identifying these risks is important – if a doctor was considering prescribing my friend’s medication to an obese smoker in his 60s with a strong family history of heart disease, a 16% increase in risk might be unacceptable. But news stories like this cause concern even among young healthy people whose baseline risk of most serious health events is low – we see this every few years with the pill, for instance.

Practically, I would suggest the following: Those of you who work in medicine should be up front with your patients about these issues. If young women who were prescribed the pill were told “the pill has been shown to increase the risk of blood clots, however, because you are a non-smoker under thirty the risk to you is extremely low” they would be less liable to panic when the next round of news stories about a one in a million event goes around.

Those of you who are patients, when you see stories like this, need to consider what you know about your own risk of the event in the news story. Do you have a family history of heart disease or a particular type of cancer? Are you of an age where your risk of that event is actually meaningful, or do you know that this event is very rare in people your age? Knowing the numbers may be useful, but you’ll probably have an intuitive sense – do you know anybody who’s had a heart attack under 40, for instance? I don’t. They’re rare.

If you think the risk is meaningful or you just want to be sure, talk to your doctor and they should be able to walk you through it. But remember that the newspapers aren’t worried about your health – they want clicks. And when you see a story like this, and freak out, and share it with all your friends, who freak out, and share it with all their friends, the papers gets what they want. All you get is a bad night’s sleep.

Posted in Uncategorized | Leave a comment

The South African Trap

So I’m in Cape Town, and the wealth inequality is insane. It is like nothing I have ever seen – not in India, not in Malaysia, certainly not in Kenya. Take the 1% from Australia and put them in the same city as Kibera, and you have Cape Town. Half an hour from where I’m staying is a township of 450k people with a HIV prevalence of 30%, where people live in corrugated iron shacks that regularly burn down due to jerry rigged electricity supplies. My neighbour, meanwhile, owns two new BMWs, and I regularly see people driving absolutely fucking ridiculous brand new sports cars through town.

I am also working with census data, and it has revealed something I had never quite got into order in my head before. South Africa is young. 45% of the population in under 25, 30% are kids. Of its 53 million residents, only 36 million are adults of working age. Of these, only 20 million are “economically active” – available for, or undertaking, paid work. Of those, only 15 million are currently employed. I knew about the age structure, but what I hadn’t previously grasped is that it is a problem for redistributive taxation. Like, a big one.

South Africa has, as far as I can tell, a nearly identical income tax system to Australia’s. There’s a tax-free threshold, then a tax rate that starts at 18% and rises to 40%. Unlike Australia, however, bureaucracy here is completely insane and the government’s ability to actually collect tax from recalcitrant citizens is probably compromised. Wiki tells me that of South Africa’s 15 million employed adults, only 3.5 million paid tax in 2012. Of course, in addition to problems with collection, many people will also be earning below the tax free threshold.

I have always been frustrated by Australia and other Western countries wringing their hands about ageing populations and shrinking tax bases, while strongly restricting immigration from lower and middle income countries. However, I’ve also been aware of the issue of high income countries benefiting from the migration of skilled people from middle income countries, who are replaced by skilled people from lower income countries. South Africa pays to train doctors who migrate to Australia and the UK. Those South African doctors are replaced by doctors who were trained in Congo and Malawi, at significant cost to the those countries. Some of those doctors are replaced by well intentioned people from high income countries, either permanently or temporarily via organisations by MSF – but not enough of them, and not sustainably. This pattern is repeated on every continent. In effect, lower income countries subsidise the skilled labour markets of higher income countries. This is, needless to say, both unjust and profoundly destructive for people in lower income countries.

But the census and employment data made me realise something else. The loss of doctors and other skilled professionals is not only an issue because it reduces the number of people able to provide essential services – it also shrinks the tax base in lower and middle-income countries, and from the top, since they lose high-income earners who would contribute the most tax. The problem is compounded even further, for countries like South Africa, by the family structures of those people relative to lower-income citizens of the same country.

Almost half of Australia’s population is both economically active and employed, compared to only 30% of South Africa’s population. The majority of people in Australia who are not economically active are aged over 65, and many of them have superannuation, which reduces their reliance on redistributive taxation. In South Africa, in contrast, the majority of people who are not economically active are either children, people who are ill or disabled, or women staying at home to care for one of the first two groups. Each of those groups is reliant either on adult relatives to earn income, or on redistributive taxation, for survival. South Africa has a system of “grants” (benefits) provided for children and people with disabilities, although they are meagre, and these are funded through taxation.

Now, not only does the migration of high earners erode the tax base from the top, it also increases the ratio of people who are economically dependent on others (kids and the disabled) to people who are earning and paying tax. High income earners tend to have fewer children than low income earners, or in many cases, they are young people who are yet to have kids at all. They are also generally unable to bring ill or disabled relatives with them to higher income countries (although they can, and often do, send money home). So the migration of a doctor from South Africa to Australia removes a high-income earner, eroding the tax base, but probably does not remove a sufficient number of people who are economically dependent on redistribution for the country to break even.

South Africa is a country of staggering wealth inequality, but the demographic and economic factors I’ve just described make it extremely difficult to address that problem through redistributive taxation alone. If South Africa were to increase its top tax rate, this would potentially hasten the rate of skilled emigration, further exacerbating the problem I’ve just described. If all skilled high-income earners left South Africa the inequality would obviously be reduced, but the poverty of the worst off would actually be exacerbated by the reduced tax revenue.

I regret to say I do not have a magical solution to this problem, although something I would like to see in a more just world would be higher income countries compensating lower income countries for the loss of skilled workers. I wrote about this issue obliquely last year, discussing how long it will take the health systems in the Ebola-affected countries to recover from the epidemic, since they cannot afford to train sufficient numbers of health professionals to replace the hundreds who died. Australia and other high-income countries are currently being subsidised by lower income countries who pay to train medical and other skilled staff, who then emigrate. I don’t think the solution to that is to restrict skilled migration even further, but perhaps we should be compensating those countries not only for the skilled workers they’ve lost, but also for the erosion of their tax bases. Looked at in this way, foreign aid is not actually charity – it’s the payment of a long overdue and very substantial bill. We owe much more than we think.

Posted in Uncategorized | 1 Comment