xoa.thermdyn.mixed_layer_depth

xoa.thermdyn.mixed_layer_depth(da, method=None, zref=0.0, deltatemp=0.2, deltadens=0.3, kzmax=0.0005, zdim=None, dask='parallelized', **kwargs)[source]

Compute the mixed layer depth with different methods.

Parameters:
  • da (xarray.DataArray) – A data array that contains either the potential temperature, the potential density or the vertical tracer diffisivity. Note that this array must contain a depth coordinate, which optimally contains the positive attribute.

  • method ({'deltatemp', 'deltadens', 'kzmax'}) –

    Method for computing the mixed layer depth

    • 'deltatemp': depth at which the potential temperature is deltadtemp lower than the surface temperature

    • 'deltadens': depth at which the potential density is deltadens higher than the surface density

    • 'kzmax': depth at which the vertical diffusivity value reaches the kzmax value

  • zref (float) – Reference depth (in meters) from which the MLD_METHODS are applied

  • kwargs (dict) – Extra keywords are passed to xoa.regrid.isoslice().

Raises:

XoaError: – When method is None and cannot be inferred from da.

Returns:

xarray.DataArray – Mixed layer depth