Saturday, September 21, 2013

GDP per capital by country, case study

Countries with small populations will have large sample variances, whereas countries with large population will have much smaller sample variances. There is a Ted talk on this, but I had not found the original video. I only remember it is from a population geneticist.

SEM = sigma / sqrt(sample_size)

R code for demo

world = rnorm(7.1E3)  #world population 7.1 billion
china = sample(world, 1.1E3)  #china 1.1 billion
c1 = sample(world, 20) #20 million pop for country c1

itr = 100
list.china = numeric(itr)
list.c1 = numeric(itr) 
for( i in 1:itr){
 list.china[i] = mean( sample(world, 1.1E3) )
 list.c1[i] = mean(sample(world, 20)  )
}


Reference: 

http://ablog.typepad.com/keytrendsinglobalisation/2013/05/only-30-of-the-world-now-has-a-higher-gdp-per-capita-than-china.html

Ted video on GDP per capital by country.





No comments:

Post a Comment