RSI | R Documentation |
Returns the Relative Strength Index with adjustable periods
RSI(df, periods, current = FALSE, pricechange = NULL, hideprints = TRUE)
df |
Dataframe with price data |
periods |
Calculation Period |
current |
If one wants to input the latest price point before data updates, RSI uses the percentage return at the end of the market hours |
pricechange |
Input in percentage |
hideprints |
If TRUE, hides printouts from the current message |
Returns a vector of RSI calculations in dataframe format. If current = TRUE, returns the most recent RSI.
RSI(SPY15, 14) RSI(tail(SPYdaily,200), 14, current = TRUE, pricechange = 1.3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.