Fast and efficient computation of rolling and expanding statistics for time-series data.
roll is a package for R that provides fast and efficient computation of rolling statistics for time-series data.
Get the released version from CRAN:
install.packages("roll")
Or the development version from GitHub:
# install.packages("devtools")devtools::install_github("jjf234/roll")
roll_median
, roll_min
, roll_max
, roll_any
, and roll_all
functions for computing rolling medians, minimums, maximums, any, and all, respectively, of time-series data (#4, #13, #14)
roll_median
, roll_min
, and roll_max
functions are not calculated using online algorithmsAdded online
argument to process observations using online algorithms by default
roll_lm
function now returns standard errors (#7)
Simplified checks for width
and min_obs
arguments (#3)
Added y
argument to roll_cov
and roll_cor
functions (#2)
Updated src/Makevars
and src/Makevars.win
files to what the RcppArmadillo
skeleton default now uses to more fully utilize OpenMP
RcppParallel
package to one with the setThreadOptions
functionDeprecated less common functions (roll_eigen
, roll_vif
, and roll_pcr
) and arguments (scale
and center
in the roll_lm
function); also removed the parallel_for
argument in favor of a new approach used internally
New roll_sum
and roll_prod
functions for computing rolling sums and products, respectively, of time-series data
Added init.c
file with calls to R_registerRoutines()
and R_useDynamicSymbols()
; also uses .registration = TRUE
in useDynLib
in NAMESPACE
Added intercept
argument to roll_lm
and roll_pcr
functions
Turned on CXXSTD = CXX11
to enforce adherence to the C++11 standard
Added a section on examples to the README
file
Fixed an issue in the src/Makevars
and src/Makevars.win
files (#1)
roll_lm
and roll_pcr
functions have been enhanced:
y
can now be a matrix or xts object with multiple dependent variables
Added shorthand arguments for center
and scale
New roll_scale
function for computing rolling scaling and centering of time-series data