cartopy.feature.NaturalEarthFeature#

class cartopy.feature.NaturalEarthFeature(category, name, scale, **kwargs)[source]#

A simple interface to Natural Earth shapefiles.

See https://www.naturalearthdata.com/

Parameters:
  • category – The category of the dataset, i.e. either ‘cultural’ or ‘physical’.

  • name – The name of the dataset, e.g. ‘admin_0_boundary_lines_land’.

  • scale – The dataset scale, i.e. one of ‘10m’, ‘50m’, or ‘110m’, or Scaler object. Dataset scales correspond to 1:10,000,000, 1:50,000,000, and 1:110,000,000 respectively.

  • **kwargs – Keyword arguments to be used when drawing this feature.

property crs#

The cartopy CRS for the geometries in this feature.

geometries()[source]#

Returns an iterator of (shapely) geometries for this feature.

intersecting_geometries(extent)[source]#

Returns an iterator of shapely geometries that intersect with the given extent. The extent is assumed to be in the CRS of the feature. If extent is None, the method returns all geometries for this dataset.

property kwargs#

The read-only dictionary of keyword arguments that are used when creating the Matplotlib artists for this feature.

with_scale(new_scale)[source]#

Return a copy of the feature with a new scale.

Parameters:

new_scale – The new dataset scale, i.e. one of ‘10m’, ‘50m’, or ‘110m’. Corresponding to 1:10,000,000, 1:50,000,000, and 1:110,000,000 respectively.