ClimoAccessor.sel_pair

ClimoAccessor.sel_pair(key)[source]

Return selection from a pseudo “parameter” axis. “Parameter” axes are identified as any non-scalar coordinate whose associated cfvariable has a “reference” value (e.g., a coordinate named 'forcing' with a “reference” value of 0).

Parameters

key (str, optional) – The pair key. If the parameter axis is length 2, the key 1 returns the first position and the key 2 the second position. Otherwise, the key 1 returns the reference position and the key 2 is a no-op that returns the original data.

To return the difference between keys 2 and 1, pass 'anomaly'. To return the ratio of key 2 over key 1, pass 'ratio'.

The associated cfvariable names are modified by adding long_prefix and long_suffix attributes to the resulting DataArray.