Comment on page

# Gini coefficient measurement

This page illustrates the approach Rated takes in computing this metric for the Ethereum network.

The Gini coefficient (Gini) is a measure of inequality across a certain set of values. In this case, we're measuring the Gini of the validator market share of entities we have identified.

We have taken the commonality by highest order such that grouping by pools takes precedence over node operators, which take precedence over deposit addresses.

A Gini coefficient of 0 reflects perfect equality, where all income or wealth values are the same, while a Gini coefficient of 1 (or 100%) reflects maximal inequality among values.

Basing our calculation of the work by Evgeny Medvedev here, we first take the

`validator_count`

of each of the entities on the latest day and `rank`

them in descending order accordingly. We then use the `1-2B`

formula for measuring the Gini, where B is the area under the Lorenz curve such that:1 - 2 * SUM((validator_count * (rank - 1) + validator_count / 2)) / COUNT(entities) / SUM(validator_count)

The shape of a Lorenz Curve.

validator_count * (rank — 1)

is the area of the rectangular horizontal slice under the Lorenz curve.

validator_count / 2

is the area of the triangle on the left of the rectangular slice.

SUM((validator_count * (rank — 1) + validator_count / 2))

is the sum of all the slices

COUNT(entities)

normalizes the x axis to the range 0 to 1

SUM(validator_count)

normalizes the y axis to the range 0 to 1

Last modified 9mo ago