View source: R/chart_donchian.R
donchian_channel | R Documentation |
A high-level plotly::add_lines()
-wrapper function that interacts
with the TTR::DonchianChannel()
-function.
The function adds Donchian Channels
to the main chart()
.
donchian_channel(
n = 10,
include.lag = FALSE,
color = '#4682b4',
...
)
n |
Number of periods for moving average. |
include.lag |
Should values be lagged so that today's prices are not included in the calculation? See Note. |
color |
A character-vector of length 1. "#4682b4" by default. |
... |
For internal use. Please ignore. |
An invisible plotly::plot_ly()
-object.
Serkan Korkmaz
Other chart indicators:
add_event()
,
alma()
,
bollinger_bands()
,
chart()
,
dema()
,
ema()
,
evwma()
,
fgi()
,
hma()
,
lsr()
,
macd()
,
rsi()
,
sma()
,
smi()
,
volume()
,
vwap()
,
wma()
,
zlema()
Other main chart indicators:
add_event()
,
alma()
,
bollinger_bands()
,
dema()
,
ema()
,
evwma()
,
hma()
,
sma()
,
vwap()
,
wma()
,
zlema()
# script start;
# Charting BTC using
# candlesticks as main
# chart
cryptoQuotes::chart(
ticker = BTC,
main = cryptoQuotes::kline(),
sub = list(
cryptoQuotes::volume()
)
)
# script end;
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.