xoa.grid.get_dz

Contents

xoa.grid.get_dz#

xoa.grid.get_dz(obj, errors='raise', **kwargs)[source]#

Get or compute the layer thicknesses

A thickness variable is searched first. Else it is computed from the z or depth coordinate that is returned by get_z() with z2dz().

Parameters:
  • obj (xarray.DataArray, xarray.Dataset)

  • errors ({'ignore', 'warn', 'raise'}) –

    In case of errors

    • 'ignore': silently ignore

    • 'warn': emit a warning

    • 'raise': raise an exception

  • kwargs – Extra parameters are passed to z2dz()

Returns:

xarray.DataArray or None