xoa.cf.CFSpecs.match_data_var¶
- CFSpecs.match_data_var(da, name=None, loc='any')[source]¶
Check if an array matches given or any data_var specs
- Parameters
da (xarray.DataArray) –
name (str, dict, None) – Cf name. If None, all names are used. If a dict, name is interpreted as an explicit set of specifications.
loc (str, {"any", None}, {"", False}) –
str: one of these locations
None or “any”: any
False or ‘””: no location
- Returns
bool, str – True or False if name is provided, else found name or None
See also