Marine Areas/ Ocean Basins (NaturalEarth)

The outline of the marine areas are obtained from Natural Earth. They are automatically downloaded on-the-fly (but only once) with cartopy and opened with geopandas. The following marine regions are defined in regionmask:

  • Marine Areas 1:50m

The following imports are necessary for the examples.

In [1]: import regionmask

In [2]: import matplotlib.pyplot as plt

Ocean Basins

In [3]: basins = regionmask.defined_regions.natural_earth.ocean_basins_50

In [4]: basins.plot(add_label=False);

In [5]: plt.tight_layout()
_images/plotting_basins.png

Also create a mask for a 1° grid globally:

In [6]: import numpy as np

# create a grid
In [7]: lon = np.arange(0.5, 360)

In [8]: lat = np.arange(89.5, -90, -1)

In [9]: mask = basins.mask(lon, lat)

In [10]: basins.plot(add_label=False, add_ocean=False);

 # plot using xarray
In [11]: mask.plot(add_colorbar=False);

In [12]: plt.tight_layout()
_images/plotting_basins_mask.png