Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

fin-runlengths

Runlengths of a Time Series


Description

Computes runlengths of an univariate 'timeSeries' object.

Usage

runlengths(x, ...)

Arguments

x

an univariate time series of class 'timeSeries'.

...

arguments to be passed.

Value

returns an object of class timeSeries.

Examples

## random time series - 
   set.seed(4711)
   x <- rnorm(12)
   tS <- timeSeries(data=x, charvec=timeCalendar(), units="x")
   tS
   
## return runlengths -
   runlengths(tS)

timeSeries

Financial Time Series Objects (Rmetrics)

v3062.100
GPL (>= 2)
Authors
Diethelm Wuertz [aut] (original code), Tobias Setz [cre], Yohan Chalabi [ctb], Martin Maechler [ctb] (<https://orcid.org/0000-0002-8685-9910>)
Initial release
2020-01-24

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.