PovertyAndInequalityMeasures

This generates various measures poverty and inequality from a sample dataset.

The measures are mostly taken from chs. 4-6 of the World Banks' Handbook on Poverty and Inequality.

See the test case for worked examples

Poverty measures are:

  • headcount;
  • gap;
  • Foster Greer Thorndyke, for each of the values in foster_greer_thorndyke_alphas - note that α=0 is headcount and α=1 is gap;
  • Watts;
  • time to exit, for the supplied growth rate;
  • Shorrocks;
  • Sen.

See WB ch. 4 on these measures.

Inequality Measures Are:

  • Gini;
  • Atkinson, for each value in atkinson_es;
  • Theil;
  • generalised_entropy;
  • Hoover;
  • Theil;
  • Palma.

See World Bank chs. 5 an 6, and Cobham and Sumner on the Palma. Also returned by the inequality function are:

  • total_income
  • total_population
  • average_income
  • deciles.

There's also a small binify routine which chops a dataset up into chunks of cumulative income and population suitable for drawing Lorenz Curves.

Index

PovertyAndInequalityMeasures.add_decomposed_theilMethod

Make a wee dict with :theilbetween and :theilwithin See WB eqns 6.7/6.8. TODO

  1. there are some papers on decomposing Atkinson, but I

don't understand them ..

  1. the over time 3-part version

popindc : Inequal for the population as a whole subindices : an array of dics, one for each subgroup of interest

source
PovertyAndInequalityMeasures.binifyFunction

Chop a dataset with populations and incomes into numbins groups in a form suitable for e.g. a Gini curve.

  • col1 is cumulative population,
  • 2 cumulative income/whatever,
  • 3 threshold income level.
source
PovertyAndInequalityMeasures.make_inequalityFunction

Make a struct of inequality measures. This is mainly taken from chs 5 and 6 of the World Bank book.

  1. rawdata a matrix with cols with weights and incomes
  2. atkinson_es inequality aversion values for the Atkinson indexes
  3. generalised_entropy_alphas
  4. weightpos - column with weights
  5. incomepos - column with incomes

Returned is a Dict of inequality measures with:

  • Gini;
  • Atkinson, for each value in atkinson_es;
  • Theil;
  • generalised_entropy;
  • Hoover;
  • Theil;
  • Palma.

See WB chs 5 an 6, and Cobham and Sumner on the Palma.

Also in the struct are:

  • total_income
  • total_population
  • average_income
  • deciles.
source
PovertyAndInequalityMeasures.make_inequalityinternalMethod

Make a dictionary of inequality measures. This is mainly taken from chs 5 and 6 of the World Bank book.

  1. rawdata a matrix with cols with weights and incomes
  2. atkinson_es inequality aversion values for the Atkinson indexes
  3. generalised_entropy_alphas
  4. weightpos - column with weights
  5. incomepos - column with incomes
source
PovertyAndInequalityMeasures.make_povertyFunction

Create a dictionary of poverty measures.

This is based on the World Bank's Poverty Handbook by Haughton and Khandker.

Arguments:

  • rawdata - an nxm array of real nunbers; each row is an observation; one col should be a weight, another is income; positions assumed to be 1 and 2 unless weight and incomepos are supplied
  • line - a poverty line, assumed same for all obs (so income is assumed to be already equivalised)
  • foster_greer_thorndyke_alphas - coefficients for FGT poverty measures; note that FGT(0) corresponds to headcount and FGT(1) to gap; count and gap are computed directly anyway but it's worth checking one against the other.
  • growth is (e.g.) 0.01 for 1% per period, and is used for 'time to exit' measure.

Output is dictionary with an entry for each measure.

The measures are:

  • headcount;
  • gap;
  • Foster Greer Thorndyke, for each of the values in foster_greer_thorndyke_alphas;
  • Watts;
  • time to exit, for the supplied growth rate;
  • Shorrocks;
  • Sen.

See World Bank, ch. 4.

source
PovertyAndInequalityMeasures.make_povertyFunction

As above, but using the QueryVerse IterableTables interface rawdata - basically anything resembling a dataframe; see: [https://github.com/queryverse/IterableTables.jl] throws an exception if rawdata doesn't support iterabletable interface

source

TODO

  • better decomposable indices;
  • having separate dataframe/array versions seems complicated.

Bibliography

Cobham Alex, and Sumner Andy. “Is Inequality All about the Tails?: The Palma Measure of Income Inequality.” Significance 11, no. 1 (February 19, 2014): 10–13. https://doi.org/10.1111/j.1740-9713.2014.00718.x.

Haughton, Jonathan, and Shahidur R. Khandker. ‘Handbook on Poverty and Inequality’. The World Bank, 27 March 2009. http://documents.worldbank.org/curated/en/488081468157174849/Handbook-on-poverty-and-inequality.

Preston, Ian. ‘Inequality and Income Gaps’. IFS Working Paper. Institute for Fiscal Studies, 5 December 2006. https://econpapers.repec.org/paper/ifsifsewp/06_2f25.htm.

Reed, Howard, and Graham Stark. ‘Tackling Child Poverty Delivery Plan - Forecasting Child Poverty in Scotland’. Scottish Government, 9 March 2018. http://www.gov.scot/Publications/2018/03/2911/0``.