zscores.ma: Zscore based Moving Average

Description Usage Arguments Value Examples

View source: R/Utilities.R

Description

Using moving averages to compute the z-score of the ratio at each given time. This will tell us how extreme the ratio is and whether it's a good idea to enter a position at this time.

Usage

1
zscores.ma(t, long = 60, short = 10)

Arguments

t

a time-series to be normalized

long

days of long-term moving averages

short

days of short-term moving averages

Value

A normalized time-series

Examples

1
2
3
library(quantmod)
getFX("AUD/USD")
zscores.ma(AUDUSD, 60, 10)

ivanliu1989/RQuantTrader documentation built on Sept. 13, 2019, 11:54 a.m.