Measure distribution inequality (income, wealth, or any data) from raw data, visualize the Lorenz curve, and compare two groups — all in your browser.
Enter a list of values (separated by commas, spaces, or newlines). Data is automatically sorted ascending before being computed with the discrete formula G = (2·∑i·xi)/(n·∑x) − (n+1)/n.
Note: results are only as accurate as the data you enter. Negative values are rejected because the standard Gini coefficient uses non-negative data.
Enter the same raw data as in mode 1 — the calculator computes cumulative points (population % vs income %) then draws the Lorenz curve along with the perfect-equality line.
Compare the inequality of two data groups — e.g. two regions, two time periods, or income vs wealth.
What is the Gini coefficient?
The Gini coefficient is a single number between 0 and 1 measuring how unequal the distribution of a quantity, e.g. income or wealth, is within a group. A value of 0 means perfect equality since everyone receives the same amount, while 1 means maximum inequality since one person controls the entire total. This calculator computes the Gini from the raw data you enter.
What is the Gini coefficient formula for discrete data?
For data sorted ascending x_1 through x_n, the formula is G = (2 \u00d7 sum(i \u00d7 x_i)) / (n \u00d7 sum x) \u2212 (n+1)/n, where i is the data rank starting at 1. Example: data 10, 20, 30, 40 gives sum x = 100 and sum(i \u00d7 x_i) = 300, so G = (2 \u00d7 300) / (4 \u00d7 100) \u2212 5/4 = 1.5 \u2212 1.25 = 0.25. This formula is used by the raw-data calculation mode on this page.
How do you read a Gini coefficient value between 0 and 1?
The closer to 0, the more equal the distribution; the closer to 1, the more unequal. As a descriptive guide, this calculator uses the ranges: below 0.25 low inequality, 0.25 to 0.4 moderate inequality, 0.4 to 0.5 high inequality, and above 0.5 very high inequality. These ranges are only descriptive labels for reading the number, not good-or-bad judgments.
What is the relationship between the Gini coefficient and the Lorenz curve?
The Lorenz curve plots the cumulative percentage of the population on the horizontal axis against the cumulative percentage of income on the vertical axis, after sorting the data ascending. The diagonal line is the perfect-equality line. The Gini coefficient equals the area between the diagonal line and the Lorenz curve divided by the total area under the diagonal line. Example data 1, 2, 3, 4 yields curve points (25 percent, 10 percent), (50 percent, 30 percent), (75 percent, 60 percent), and (100 percent, 100 percent).
What are the limitations of the Gini coefficient?
The Gini coefficient summarizes an entire distribution into one number, so two very differently shaped distributions can have the same Gini value. It also does not explain the source of inequality \u2014 e.g. whether it comes from wage differences, asset ownership, or other factors \u2014 and does not capture income mobility over time. A Gini figure is more meaningful when read together with the Lorenz curve and other indicators, not as the sole measure.
What is the difference between the income Gini coefficient and the wealth Gini coefficient?
The income Gini coefficient measures inequality of the earnings flow within one period, e.g. annual salary, while the wealth Gini coefficient measures inequality of the net-asset stock such as savings, property, and investments. Both use the same formula, but the data differs and results cannot be compared directly because wealth is generally distributed more unequally than income. This calculator computes both as long as the entered data fits.
Can this calculator be used for country or regional data?
Yes, as long as you have the data, e.g. per-capita income for each province or population group. However, the resulting figure is only as accurate as the entered data, and cross-region comparisons are only meaningful when the data definitions and periods match. This page is educational and does not provide policy or financial advice.
Free tool by NRTechStudio
Explore similar finance tools and calculators. 100% free, accurate, and runs completely in your browser without sign-up.
2 taps, no typing needed — diagnostics are sent automatically.