tau2time | R Documentation |
Convert changepoint sets to time indices
tau2time(tau, index)
time2tau(cpts, index)
tau |
a numeric vector of changepoint indices |
index |
Index of times, typically returned by |
cpts |
Time series observation labels to be converted to indices |
tau2time()
: a character
of time labels
time2tau()
: an integer
vector of changepoint indices
stats::time()
, as_year()
# Recover the years from a set of changepoint indices
tau2time(c(42, 81, 330), index = as_year(time(CET)))
# Recover the changepoint set indices from the years
time2tau(c(1700, 1739, 1988), index = as_year(time(CET)))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.