How did the authors of the (Credit Suisse) Global Wealth Databook calculate the Gini coefficient?

how are you doing? I read the Global Wealth Reports from Credit Suisse and I wondered how the authors calculated the Gini coefficient. For example, on page 84 of this databook from 2010, how did they calculate it? Can somebody show me how they did it? I would like to recalculate it in excel. Thank you very much.

Example from the Databook 2010 • For the USA they probably used something like the Survey of Consumer Finances and similarly in other countries Nov 7 '20 at 1:44

The GINI has fairly standardized calculation so you can just follow the standard formulas. The GINI is the ratio of the grey area on the plot below (taken from wikipedia - which also mentions the formulas below) to the total area. Hence if you already have data where these areas are calculated you can simply compute GINI as:

$$GINI= \frac{A}{A+B}$$

If you have raw data then you can use formula:

$$GINI= \frac{\sum^n_{i=1}\sum^n_{j=1} |x_i-x_j| }{2n^2 \bar{x}}$$

where $$x_i$$ is the income of person $$i$$ (or if you are calculating wealth inequality wealth of person $$i$$). The formula above can be also rearranged in a different ways, so some textbooks/sources can express it in different way but the results will match.

Next the formula could be also expressed in terms of income distribution:

$$GINI= \frac{1}{2\mu} \int \int p(x_i) p(x_j) | x_i - x_j | dx_i dx_j$$

where $$\mu$$ is the mean of distribution of $$x_i$$.

You can find more on these in Sen, Amartya (1977), On Economic Inequality (2nd ed.). If you want something solely focused on GINI then Yitzhaki and Schechtman. The Gini methodology: A primer on a statistical methodology. Vol. 272. has an exhausting literature review on GINI. 