mpas_analysis.ocean.utility.add_standard_regions_and_subset
- mpas_analysis.ocean.utility.add_standard_regions_and_subset(ds, config, regionShortNames=None)[source]
Add standard region names (
regionNames
coordinate) to a dataset and renamenOceanRegionsTmp
dimension tonOceanRegions
(if present). Shorter standard region names are inregionNamesShort
.- Parameters:
ds (xarray.Dataset) – the dataset to which region names should be added
config (mpas_tools.config.MpasConfigParser) – Configuration options
regionShortNames (list of str, optional) – A list of a subset of the short region names to use to subset the dataset
- Returns:
ds (xarray.Dataset) – the dataset with region names added and possibly subsetted