regionmask.Regions.plot_regions

Regions.plot_regions(*, ax=None, add_label=True, label='number', line_kws=None, text_kws=None, label_multipolygon='largest', tolerance='auto')

plot regions on regular axes

Parameters:
axaxes handle, optional

If given, uses existing axes. If not given, uses the current axes or creates new axes. In contrast to Regions.plot this does not create a cartopy axes.

add_labelbool, default: True

If True labels the regions.

label‘number’ | ‘name’ | ‘abbrev’, default: ‘number’

If ‘number’ labels the regions with numbers, if ‘name’ uses the long name of the regions, if ‘abbrev’ uses abbreviations of the regions. Default ‘number’.

line_kwsdict, optional

Arguments passed to plot.

text_kwsdict, optional

Arguments passed to the labels (ax.text).

label_multipolygon‘largest’ | ‘all’, default: ‘largest’

If ‘largest’ only adds a text label for the largest Polygon of a MultiPolygon. If ‘all’ adds text labels to all of them.

toleranceNone | ‘auto’ | float, default: ‘auto’.

Maximum length of drawn line segments. Can lead to better looking plots on certain maps.

  • None: draw original coordinates

  • float > 0: the maximum (euclidean) length of each line segment.

  • ‘auto’: None if a matplotlib axes is passed. If a cartopy GeoAxes is passed the tolerance is automatically determined based on the log10 of the largest absolute coordinate. Defaults to 1 for lat/ lon coordinates.

Returns:
axaxes handle