CHM.xarray_accessor.GeoAccessor.clip

CHM.xarray_accessor.GeoAccessor.clip#

xarray_accessor.GeoAccessor.clip(lat=None, lon=None, shp_file_path=None) UxDataset#

Subset face-centered variables to a lat/lon bounding box or a geometry extent.

Parameters#

latlist[float], optional

Two-element list defining latitude bounds [min, max].

lonlist[float], optional

Two-element list defining longitude bounds [min, max].

shp_file_pathstr, optional

Shapefile/GeoJSON path used to derive bounds when lat/lon are omitted.

Returns#

ux.UxDataset

Subset dataset retaining uxgrid metadata and coordinates.