Loading the result into ArcGIS Online
The final merge involves combining the shapefile we collected from ArcGIS Online and the data frame from the FAO and World Bank to give our data frame geometry for visualization. The df_master
'name'
column needs to be renamed to match the shapefiles’ 'COUNTRY'
column. Then, the two datasets will be merged on that column:
- In the next cell, you will rename the column containing the country name in
df_master
to match the country name column in the SEDF. Then, you will merge the columns on that column and remove unnecessary columns:df_master.rename(columns={'name':'COUNTRY'}, inplace=True) sdf_master = sdf.merge(df_master, on='COUNTRY') sdf_master = sdf_master.drop(['ISO', 'COUNTRYAFF', 'AFF_ISO', 'FID'], axis=1)
Run the cell.
- The data frame merged above,
sdf_master
, will be exported to a shapefile and...