mirror of
https://github.com/freqtrade/freqtrade.git
synced 2024-11-10 10:21:59 +00:00
18 lines
464 B
Django/Jinja
18 lines
464 B
Django/Jinja
|
|
# Momentum Indicators
|
|
# ------------------------------------
|
|
|
|
# RSI
|
|
dataframe['rsi'] = ta.RSI(dataframe)
|
|
|
|
# Retrieve best bid and best ask from the orderbook
|
|
# ------------------------------------
|
|
"""
|
|
# first check if dataprovider is available
|
|
if self.dp:
|
|
if self.dp.runmode.value in ('live', 'dry_run'):
|
|
ob = self.dp.orderbook(metadata['pair'], 1)
|
|
dataframe['best_bid'] = ob['bids'][0][0]
|
|
dataframe['best_ask'] = ob['asks'][0][0]
|
|
"""
|