Plot Regional DataΒΆ
Out:
model scenario region variable unit year value
0 MESSAGE-GLOBIOM SSP2-26 ABW Emissions|CO2 Mt CO2/yr 2050 159.556
1 MESSAGE-GLOBIOM SSP2-26 AFG Emissions|CO2 Mt CO2/yr 2050 5874.171
2 MESSAGE-GLOBIOM SSP2-26 AGO Emissions|CO2 Mt CO2/yr 2050 3111.971
3 MESSAGE-GLOBIOM SSP2-26 AIA Emissions|CO2 Mt CO2/yr 2050 159.556
4 MESSAGE-GLOBIOM SSP2-26 ALA Emissions|CO2 Mt CO2/yr 2050 5387.476
import cartopy
import pyam
import matplotlib.pyplot as plt
fname = 'data.csv'
df = pyam.IamDataFrame(fname, encoding='ISO-8859-1')
df = (df
.filter({'variable': 'Emissions|CO2', 'year': 2050})
.filter({'region': 'World'}, keep=False)
.map_regions('iso', region_col='R5_region')
)
print(df.head())
df.region_plot(crs=cartopy.crs.Robinson())
plt.show()
Total running time of the script: ( 0 minutes 0.336 seconds)