| TA {quantmod} | R Documentation |
Add Technical Indicator to Chart
Description
Functions to add technical indicators to a chart.
Details
The general mechanism to add technical analysis studies or overlays
to a financial chart created with chartSeries.
General TA charting tool functions:
-
addTA: add data as custom indicator -
dropTA: remove technical indicator -
moveTA: move a technical indicator -
swapTA: swap two technical indicators
Current technical indicators include:
-
addADX: add Welles Wilder's Directional Movement Indicator -
addATR: add Average True Range -
addAroon: add Aroon Indicator -
addAroonOsc: add Aroon Oscillator -
addBBands: add Bollinger Bands -
addCCI: add Commodity Channel Index -
addCMF: add Chaiken Money Flow -
addChAD: add Chaiken Accumulation Distribution Line -
addChVol: add Chaiken Volatility -
addCMO: add Chande Momentum Oscillator -
addDEMA: add Double Exponential Moving Average -
addDPO: add Detrended Price Oscillator -
addEMA: add Exponential Moving Average -
addEMV: add Arm's Ease of Movement -
addEnvelope: add Moving Average Envelope -
addEVWMA: add Exponential Volume Weighted Moving Average -
addExpiry: add options or futures expiration lines -
addKST: add Know Sure Thing -
addLines: add line(s) -
addMACD: add Moving Average Convergence Divergence -
addMFI: add Money Flow Index -
addMomentum: add Momentum -
addOBV: add On-Balance Volume -
addPoints: add point(s) -
addROC: add Rate of Change -
addRSI: add Relative Strength Indicator -
addSAR: add Parabolic SAR -
addSMA: add Simple Moving Average -
addSMI: add Stochastic Momentum Index -
addTDI: add Trend Direction Index -
addTRIX: add Triple Smoothed Exponential Oscillator -
addVo: add Volume (if available) -
addVolatility: add volatility -
addWMA: add Weighted Moving Average -
addWPR: add Williams Percent R -
addZigZag: add Zig Zag -
addZLEMA: add ZLEMA
See the individual functions for specific implementation and argument details. Details of the underlying TTR implementations can be found in TTR.
The primary changes between the add*** version of an indicator and the TTR base function is the absense of the data argument in the former.
Notable additions include on, with.col.
Value
Called for its side effects, an object to class chobTA
will be returned invisibly. If called from the R command line
the method will draw the appropriate indicator on the current chart.
Note
Calling any of the above methods from within a function or script
will generally require them to be wrapped in a plot call
as they rely on the context of the call to initiate the actual
charting addition.
Author(s)
Jeffrey A. Ryan
References
Josh Ulrich - TTR package