How Labour estimated ethnicity from surnames

How Labour estimated ethnicity from surnames

In response to requests via Twitter, this post walks readers through the general method Labour used to predict the ethnicity of Auckland house buyers from their surnames. This analysis was featured in the New Zealand Herald's lead story yesterday.

Note that there are two points in this explanation where I will refuse to go into further detail, in order to protect Labour IP. The rest of this explanation has been made publicly in various venues already, so this post does not give away any new secrets.

Part 1: 2014 demographic study

Pre-election, Labour estimated the ethnicity of every person on the electoral roll, via standard Bayesian updating. There are 3.2 million people on the roll. This was one of many demographic estimates we did for everyone in the country. Most serious political parties now engage in this kind of demographic profiling.

To estimate ethnicity, we used public NZ census data on the ethnic distribution of neighbourhoods, and also used data we developed privately about the ethnic distribution of last, middle, and first names in New Zealand. We followed some advice – especially about estimating Asian ethnicities - from prominent US academic studies. I won’t be describing that process further, as that is sensitive IP for Labour.

Using these data, our base method was to estimate people’s ethnicity in a three-step Bayesian analysis:

  • Step 1: Prior: Neighbourhood ethnic distribution. New information. Lastname distribution. Posterior: Neighbourhood / lastname ethnic distribution.
  • Step 2: Prior: Neighbourhood / lastname ethnic distribution. New information. Firstname distribution. Posterior: Neighbourhood / lastname / firstname ethnic distribution.
  • Step 3: Prior: Neighbourhood / lastname / firstname ethnic distribution. New information. Middlename distribution. Posterior: Neighbourhood / lastname / firstname / middlename ethnic distribution.

This process provides a distribution of the likely ethnicities of each person in New Zealand, given their address and their full name.

The distribution covered the probability that a person was each of the following ethnicities, drawn from the level 1 and level 2 ethnic classifications from the New Zealand census: European, Maori, Pacific (not further defined), Pacific (Samoan), Pacific (Tongan), Asian (not further defined), Asian (Chinese), Asian (Japanese), Asian (Korean), Asian (South Asian), Asian (Middle East), other.

For the person-level point estimates, we used the largest single probability. That probability was typically above 0.9.

We refined these estimates further with three tweaks to account for moderate issues we encountered estimating certain ethnicities. I won’t be describing those tweaks further, because IP.

We then tested our predictions against a more-or-less-random sample of around 3,500 known New Zealanders for whom we had ethnicity data. Our best predictions, which we have used since, were 94.8% accurate.

This is an important point. Having developed our method for estimating ethnicity, we then tested it for accuracy against real world data. Only once we were satisfied it was accurate were we willing to rely on it in our work.

Part 2: Applying the predictions to housing data

To apply our general predictions, derived in part 1 above, to the Auckland housing data, we followed a two-step process.

First, we collapsed the 1.4 million Auckland-based ethnic estimates we had by surname only, as that is the only data we had in the real estate data. This allowed us to also partly leverage the earlier electoral roll-based information we gleaned from first names, middle names, and locations as part of our surname-based estimates.

Most of the surnames pointed strongly (pr>0.9) to one and only one ethnicity, although there were some examples with more mixed predictions. It created estimates such as the following (these are the real values):

Name pr(European) pr(Maori) pr(Chinese) pr(other)
JONES 0.938 0.054 0.001 0.007
HOTERE 0.048 0.887 0.000 0.065
LEE 0.481 0.027 0.400 0.092
LI 0.028 0.001 0.957 0.014

Having done that for each individual purchaser, we then summed the probabilities across all 3,922 sales in the dataset. This provided an aggregate estimate, based on the distributions of likely ethnicities in each individual sale, for the overall ethnic distribution of house buyers in Auckland.

In doing this aggregation, we tested various ways of accounting for the fact that some sales had one surname attached, while others had two or even three, accounting for multiple people with diffrerent surnames purchasing a property together. No matter how we cut those observations, the overall pattern remained within 2% of the numbers that appeared in the New Zealand Herald.

It is that overall distribution, not data cherry-picked from any particular sale, that we then compared with various other aggregate datasets about the ethnic distribution of Auckland residents, or various subsets of Auckland residents. Many of those comparisons are detailed in the Herald article and in my Public Address blog post yesterday.

Filed under: 

Commenting on this Blog entry will be automatically closed on July 16, 2015.

Comments

Is there a separate statistical explanation for how you got from the imputed ethnicity to the asserted non-residency of house purchasers?

buzzfeed says:

The information you have posted is very useful. The sites you have referred was good. Thanks for sharing..
barnehage

Nasreenknawal says:

I appreciate your work. Keep it up. Web Freer Crack

thomas1122 says:

I have read a few of the articles on your website now. and I really like your style of blogging. I added it to my favorites blog site list and will be checking back soon. Please check out my site as well and let me know what you think.
geek gifts for men

thomas1122 says:

I'm glad I found this web site. I couldn't find any knowledge on this matter prior to.Also operate a site and if you are ever interested in doing some visitor writing for me if possible feel free to let me know. im always look for people to check out my web site.
career planning

jams says:

I wish more authors of this type of content would take the time you did to research and write so well. I am very impressed with your vision and insight.
forum about hemorrhoids

wallens says:

Thank you a bunch for sharing this with all of us you actually realize what you are talking about! Bookmarked. Please also seek advice from my site =). We could have a hyperlink change contract between us! read more here

jams says:

Very useful post. This is my first time i visit here. I found so many interesting stuff in your blog especially its discussion. Really its great article. Keep it up.
Amstaff

carissa30 says:

You have a real ability for writing unique content. I like how you think and the way you represent your views in this article. I agree with your way of thinking. Thank you for sharing. disciples iii renaissance

carissa30 says:

Thankyou for this wondrous post, I am happy I watched this site on hurray. look younger

japan says:

This is exceptionally instructive substance and composed well for a change. It's pleasant to see that a few individuals still see how to compose a quality post! buy youtube views

johnb6174 says:

The information you have posted is very useful. The sites you have referred was good. Thanks for sharing...
Augusto de Arruda Botelho

johnb6174 says:

Your blog provided us with valuable information to work with. Each & every tips of your post are awesome. Thanks a lot for sharing. Keep blogging..
imoveis miami

johnb6174 says:

I appreciate everything you have added to my knowledge base.Admiring the time and effort you put into your blog and detailed information you offer.Thanks.
classified

johnb6174 says:

Its a great pleasure reading your post.Its full of information I am looking for and I love to post a comment that "The content of your post is awesome" Great work.
acne treatment

johnb6174 says:

Thank you for such a well written article. It’s full of insightful information and entertaining descriptions. Your point of view is the best among many.
Cheap Price Drones

wallens says:

Very good points you wrote here..Great stuff...I think you've made some truly interesting points.Keep up the good work. freeapkdownloader

johnb6174 says:

Thank you for such a well written article. It’s full of insightful information and entertaining descriptions. Your point of view is the best among many.
your cannabis planet

johnb6174 says:

I really appreciate the kind of topics you post here. Thanks for sharing us a great information that is actually helpful. Good day!
dental practice seo

wallens says:

Great write-up, I am a big believer in commenting on blogs to inform the blog writers know that they’ve added something worthwhile to the world wide web!.. Bangladeshi Model

wallens says:

Great content material and great layout. Your website deserves all of the positive feedback it’s been getting. Blackhead remover review

asdasd says:

The information you have posted is very useful. The sites you have referred was good. Thanks for sharing..

eliza says:

This is an extraordinary article it looks so fresh and genuine it does really boost me genius writing i would love to read your new post i am damn sure it would be more interesting instagram web viewer

JAMS says:

This is a great inspiring article.I am pretty much pleased with your good work.You put really very helpful information...
best weight loss gummies

JAMS says:

This is a good post. This post gives truly quality information. I’m definitely going to look into it. Really very useful tips are provided here. Thank you so much. Keep up the good works.
best pheromone cologne

asdasd says:

Great post. and great website. Thanks for the information!
varsaktanitim

asdasd says:

Thanks for taking the time to discuss that. I feel strongly about this and so really like getting to know more on this kind of field. Do you mind updating your blog post with additional insight? It should be really useful for all of us.
websites for industry

JAMS says:

Excellent article. Very interesting to read. I really love to read such a nice article. Thanks! keep rocking.
calmovil hemorrhoid relief

asdasd says:

This blog website is pretty cool! How was it made !
МГУ

JAMS says:

Most of the time I don’t make comments on websites, but I'd like to say that this article really forced me to do so. Really nice post!
icebreaker pheromone cologne for men

JAMS says:

Thanks for your post. I’ve been thinking about writing a very comparable post over the last couple of weeks, I’ll probably keep it short and sweet and link to this instead if thats cool. Thanks.
gout remedy

jordan says:

The number one website and blog to visit for animal tips, articles, advice and how to guides. Great destination for pet owners, visit Net-Pets.com
net-pets.com

jordan says:

OnDemandGrass.com is a full-service residential and commercial landscaping company servicing Plainfield, Naperville, Bolingbrook and Romeoville, IL. On Demand Grass is the only full-service landscaping company to offer on demand landscaping services in Will County, IL.
Low pricing, reliable service, locally owned and operated.
landscaping bolingbrook

asdasd says:

Your blog provided us with valuable information to work with. Each & every tips of your post are awesome. Thanks a lot for sharing. Keep blogging.
renata de abreu

asdasd says:

Thank you for such a well written article. It’s full of insightful information and entertaining descriptions. Your point of view is the best among many.
spa world

asdasd says:

Very useful post. This is my first time i visit here. I found so many interesting stuff in your blog especially its discussion. Really its great article. Keep it up.
Address Change USPS

asdasd says:

Very useful post. This is my first time i visit here. I found so many interesting stuff in your blog especially its discussion. Really its great article. Keep it up.
weight loss gummies

johnb6174 says:

I haven’t any word to appreciate this post.....Really i am impressed from this post....the person who create this post it was a great human..thanks for shared this with us.
best e liquid

eliza says:

Very interesting article, actually i was looking a website like this; It was nice to land on this website post and to see such superb stuff. I have bookmarked it and I will be back for read new blog articles instagram web viewer

jordan says:

I found your this post while redirected searching for some related information on blog search...

Pages

Add new comment