Eco Stats Mod

If you liked this item, please rate it up on Steam Workshop page.

Author: alfoirazabal

Last revision: 11 Feb, 2020 at 15:11 UTC

File size: 10.24 KB

On Steam Workshop

Description:
Economic Statistics Viewer (GDP, GDP per capita, GINI)

This It’s mostly a tool of comparisson between cities.

What do these indicators tell you

The GDP[en.wikipedia.org] will show you the size of the economy of a city.

The GDP per capita is the size of the economy divided by the population amount (often used as an indicator for how wealthy a country is, altough not considered by some to be so).

The Residential GINI[en.wikipedia.org] is an idicator ranging between 0 and 1 that tells you how much of a difference is there in the wealth of each citizen (0 means all are equally wealthy, while 1 means one citizen owns everything and the rest nothing).

The City Value per capita could be used samely as GDP, it is the city value divided by the population amount.

Government spending to GDP[en.wikipedia.org] tells you how "big" government is, or how much it spends compared to private spending. If, for example, you raise the taxes and spend much more, then government spending to GDP will be much bigger, and private spending smaller. (It’s about how much you spend not how much you take in taxes, since GDP takes in the amount of spending not the amount you as "government" take in). The less you spend and tax the more private citizens have available for spending.

How the indicators are calculated/obtained

GDP: Calculates and shows GDP, as well as Per Capita GDP, and Government and Private Spending per GDP. GDP Is calculated based on total government expenses (without loans), and assumes that non taxed private income is spent fully by citizens and organizations (industries, commercial, and offices).

GINI: Residential GINI is calculated by counting each citizen’s residential home building level, and passing it through the standard GINI Function.

City Value per Capita: Calculates the City Value per Capita, and the City Value per Capita W/O Savings (meaning, without the money stored in the city’s bank account)

The Project and source code on github is right here[github.com] for anyone to see and collaborate.

More in depth "Economics" and technical info

The formula for GDP is GDP = C + G + I + (E – M) where
C = Total sum of consumption
G = Total government spending
I = Total amount of investment
(E – M) = Net Exports (Amount of exports in $ – Amount of imports in $)

In Cities Skylines, Government spending and investment is calculated as the amount of total expenses minus loan payments (Since that does not count for GDP in the real world formula also). "Expenses" in education could be considered Investment instead of Government spending for example, but it all gets added to GDP at the end.
To calculate the total sum of consumption, we assume every private unit wether residential, commercial, or industrial spend their money in full (don’t save anything), because we have no way of knowing if they keep anything in a bank account or not. We calculate their spending based on the amount that is not taxed by the government. If taxation is 9%, for low residential for example, then the amount of low residential income that is spent is 91% (100% – 9%), now, we know that by taxing low residential units we get ‘x’ amount of money, and that equates to 9% so we simply solve ‘y’ for 91% through simple cross-multiplication. We repeat the proccess for low and high density, and for residential, commercial, and industrial. We add them all up, and get a combined amount of Consumption + Investment which all add up to GDP.
There’s only a limitation on part of the mod developer (me) with respects to calculating Total Export and Import amounts, so that the net value is added to GDP also. This limitation is due to the fact that I have not yet figuered out how to get that from the API of Cities Skylines (The Modding Application Programming Interface of Cities Skylines). As soon as I’m able to figure it out, I will add it to the mod.
After all this is added up, we obtain the final value of GDP.
GDP Per capita is self explanatory (GDP / Total Amount of Population)

GINI is a measure of statistical dispersion that outputs a result between 0 and 1.
We create a collection or list of the building level that each citizen resides in.
It loops trough every citizen and checks its homes building level, then adds it up to the collection.
After the looping is finished, we pass those numbers in the collection through a function you can find here[en.wikipedia.org]