@@ -9514,8 +9514,8 @@ def domain_mask(self, **kwargs):
9514
9514
@_inplace_enabled(default=False)
9515
9515
@_manage_log_level_via_verbosity
9516
9516
def compute_vertical_coordinates(
9517
- self, default_to_zero=True,
9518
- strict=True, inplace=False, verbose=None, key=False
9517
+ self, default_to_zero=True, strict=True, key=False,
9518
+ inplace=False, verbose=None,
9519
9519
):
9520
9520
"""Compute non-parametric vertical coordinates.
9521
9521
@@ -9550,7 +9550,7 @@ def compute_vertical_coordinates(
9550
9550
{{default_to_zero: `bool`, optional}}
9551
9551
9552
9552
strict: `bool`
9553
- If False then allow the computation to occur when
9553
+ If False then allow the computation to occur when:
9554
9554
9555
9555
* A domain ancillary construct has no standard name, but
9556
9556
the corresponding term has a standard name that is
@@ -9569,15 +9569,30 @@ def compute_vertical_coordinates(
9569
9569
names, then an exception is raised regardless of the value
9570
9570
of *strict*.
9571
9571
9572
+ key: `bool`
9573
+ If True, return alongside the field construct the key
9574
+ identifying the auxiliary coordinate of the field with
9575
+ the newly-computed vertical coordinates, as a 2-tuple
9576
+ of field and then key. If False, the default, then only
9577
+ return the field construct.
9578
+
9579
+ If no coordinates were computed, `None` will be
9580
+ returned in the key (second) position of the 2-tuple.
9581
+
9582
+ .. versionadded:: 3.17.0
9583
+
9572
9584
{{inplace: `bool`, optional}}
9573
9585
9574
9586
{{verbose: `int` or `str` or `None`, optional}}
9575
9587
9576
9588
:Returns:
9577
9589
9578
- `Field` or `None`
9590
+ `Field`, 2-tuple, or `None`
9579
9591
The field construct with the new non-parametric vertical
9580
- coordinates, or `None` if the operation was in-place.
9592
+ coordinates, or a 2-tuple of this field construct along
9593
+ with the key of the new auxiliary coordinate with the
9594
+ computed vertical coordinates, or `None` if the operation
9595
+ was in-place.
9581
9596
9582
9597
**Examples**
9583
9598
0 commit comments