cf.Constructs.filter_by_ncdim¶
-
Constructs.
filter_by_ncdim
(*ncdims)[source]¶ Select domain axis constructs by netCDF dimension name.
New in version 1.7.0.
See also
filter_by_axis
,filter_by_data
,filter_by_key
,filter_by_measure
,filter_by_method
,filter_by_naxes
,filter_by_identity
,filter_by_ncvar
,filter_by_property
,filter_by_type
,filters_applied
,inverse_filter
,unfilter
Parameters: - ncdims: optional
Select domain axis constructs that have any of the given netCDF dimension names.
A netCDF dimension name is specified by a string (e.g.
'time'
); or a compiled regular expression (e.g.re.compile('^lat')
), for which all constructs whose netCDF dimension names match (viare.search
) are selected.If no netCDF dimension names are provided then all domain axis constructs are selected.
Returns: Constructs
The selected domain axis constructs and their construct keys.
Examples:
Select the domain axis constructs with netCDF dimension name ‘time’:
>>> d = c.filter_by_ncdim('time')
Select the domain axis constructs with netCDF dimension name ‘time’ or ‘lat’:
>>> d = c.filter_by_ncdim('time', 'lat')