In Tides: Tides

Description Usage Arguments Value Author(s)

Calculate maxima and minima of quasi periodic time series. The function works good when the time series is 'smooth enough'. The function will fail when multiple local extrema exist, with a magnitude similar to the extremum extremorum and in an interval larger than [t-T2, t+T2] around the extremum extremorum at time t. When this is the case, this might be solved by adding extra wrappers around the function.

1 | ```
extrema(h, h0, T2 = 5*60*60, hoffset = 3, filtconst = 1)
``` |

`h ` |
Water level time series. data frame with time and h column |

`h0 ` |
Reference level, either single valued vector with dimension corresponding to h |

`T2 ` |
'Lower' bound on half the quasi period, but higher than expected stagnant phase; default = 5h |

`hoffset` |
Offset level, to prevent spurious maxima generation due to small fluctuations |

`filtconst ` |
Filtering constant for smoothing the time series |

a list containing:

`HL ` |
Data frame with extrema |

`h ` |
original water level data frame with additional attributes |

Tom Cox <[email protected]>

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.