calculateMixedLayerDepth: Calculate mixed layer depth

View source: R/calculations.R

calculateMixedLayerDepthR Documentation

Calculate mixed layer depth

Description

This function calculates the mixed layer depth using one of three methods implemented. Methods include the gradient, N2, and density.

Usage

calculateMixedLayerDepth(
  ctd,
  method = "gradient",
  mldMin = NULL,
  nPointsMin = 3,
  densityThreshold = 0.03,
  densityReferenceDepth = 10,
  debug = TRUE
)

Arguments

ctd

a ctd object.

method

a character string indicting which method to use to calculate the mixed layer depth, options include 'gradient', 'N2', and 'density'. Default is 'gradient'.

mldMin

a numeric value indicating the minimum value the mixed layer depth should be. Default is set to NULL. Ignored for method = 'density'.

nPointsMin

a numeric value indicating the minimum number of points in ctd object

densityThreshold

a numeric value indicating the threshold value to use for the method = density, ignored for other methods. Default is 0.03.

densityReferenceDepth

a numeric value indicating the reference depth for the method = density . It will find the closest value in the profile within 5dbar. Default is 10dbar.

debug

a logical value indicating to show debug information

Value

a single numeric value of the calculated mixed layer depth

Author(s)

Chantelle Layton and Benoit Casault


clayton33/csasMarPhys documentation built on June 8, 2025, 3:10 a.m.