Description Usage Arguments Value See Also Examples
Compute the difference in a given variable between a two depth layers, usually the surface, mixed layer and a bottom reference layer. This is often used with density to quantify the intensity of stratification.
| 1 2 | 
| x | vector of the variable of interest, usually potential or in situ density. | 
| depth | vector of depths at which  | 
| min.depths | depth(s) of reference, near the surface; when  | 
| max.depths | similar to  | 
| n.smooth | integer, number of times to smooth the data before applying the mixed layer criteria. | 
| k | order of the moving average used for smoothing; the window size is 2k+1. NB: when data is smoothed, it should have been recorded at approximately regular intervals for the moving average to make sense. | 
| fun | function used to summarise the values over  | 
The value of the stratification index.
mld() for the computation of the depth of the mixed layer, another quantification of the intensity of mixing/stratification; smooth() for smoothing.
| 1 2 3 4 5 6 7 8 9 10 11 12 | # estimate the intensity of stratification using density
plot(-depth ~ sigma, data=d, type="l")
abline(h=-c(1, 5, 61, 65), col="red")
stratif(d$sigma, d$depth, min.depths=1:5, max.depths=61:65)
stratif(d$sigma, d$depth, min.depths=1:5, max.depths=61:65, fun=median)
# estimate the intensity of the peak of chlorophyll at the deep
# chlorophyll maximum
plot(-depth ~ chla, data=d, type="l")
DCM <- maxd(d$chla, d$depth, n.smooth=2)
abline(h=-c(0, 2, DCM-2, DCM+2), col="chartreuse4")
stratif(d$chla, d$depth, min.depths=0:2, max.depths=c(DCM-2, DCM+2))
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.