import pandas as pd
= pd.read_csv('wdi.csv')
wdi
wdi.head()
#| label: setup
#| include: false
import matplotlib.pyplot as plt
import seaborn as sns
"whitegrid") sns.set_style(
World Development Indicators Analysis (2022)
Introduction
The data for this analysis comes from the World Development Indicators database (The World Bank 2022).
Loading
Life Expectancy analysis:
= wdi['life_expectancy']
life_exp_series print("Life Expectancy (Years):")
print(f"- Mean: {life_exp_series.mean():.2f}")
print(f"- Median: {life_exp_series.median():.2f}")
print(f"- Standard Deviation: {life_exp_series.std():.2f}")
Life Expectancy (Years):
- Mean: 72.42
- Median: 73.51
- Standard Deviation: 7.71
From the summary statistics in Table 1, we see that the mean life expectancy of the countries is 72.42, the median is 73.51, and the standard deviation is 7.71. In Figure 1, we see a longer and thiner tail of life expectancies on the lower end, and a shorter and thicker tail of life expectancies on the high end. In developmental economics, the Preston Curve tells us that life expectancy does not have a linear relationship to GDP per capita (Preston 1975).
Inflation analysis:
= wdi['inflation_rate']
inf_rate_series print("Inflation Rate (Annual %):")
print(f"- Mean: {inf_rate_series.mean():.2f}")
print(f"- Median: {inf_rate_series.median():.2f}")
print(f"- Standard Deviation: {inf_rate_series.std():.2f}")
Inflation Rate (Annual %):
- Mean: 12.49
- Median: 7.97
- Standard Deviation: 19.68
From the summary statistics in Table 1, we see that the mean inflation rate is 12.49 percent, the median is 7.97 percent, and the standard deviation is 19.68 percent. In Figure 2, we see a vaguely normal distribution. Most of the data points are clustered between 0 and 20 percent annual inflation, with a few outliers on the right tail. Economists have found that outlier inflation has adverse economic effects (Barro 1996).
GDP Per Capita analysis:
= wdi['gdp_per_capita']
gdp_series print("GDP Per Capita (USD):")
print(f"- Mean: ${gdp_series.mean():,.2f}")
print(f"- Median: ${gdp_series.median():,.2f}")
print(f"- Standard Deviation: ${gdp_series.std():,.2f}")
GDP Per Capita (USD):
- Mean: $20,345.71
- Median: $7,587.59
- Standard Deviation: $31,308.94
From the summary statistics in Table 1, we see that the mean GDP per capita of the countries is $20,345.71, the median is $7,587.59, and standard deviation is $31,308.94. In Figure 3, we observe that the GDP per capita of the countries in the data set follow a power law distributions. Most of the countries are clustered in the low GDP per capita buckets, a small number a clustered in middle GDP per capita buckets, and there are a tiny number of outliers with very high GDP per capita.
| | GDP per Capita ($) | Life Expectancy (Years) | Inflation Rate (%) |
|:-------------------|---------------------:|--------------------------:|---------------------:|
| Mean | 20,345.71 | 72.42 | 12.49 |
| Median | 7,587.59 | 73.51 | 7.97 |
| Standard Deviation | 31,308.94 | 7.71 | 19.68 |