rollAR: Apply AR Coefficients

Description Usage Arguments Examples

Description

Apply AR coefficients to one or multiple columns of an xts object in a rolling fashion.

Usage

1

Arguments

x

An xts object

coef

Numeric vector of AR coefficients. First element corresponds to AR1.

Examples

1
2
3
# 10-day MA crossover
growth <- diff(log(stocks))
signal <- rollAR(growth, rep(1/9,9))

jmuhlenkamp/conditionalAR documentation built on May 30, 2019, 1:59 p.m.