Timeframe
N/A
Direction
Long Only
Stoploss
-100.0%
Trailing Stop
Yes
ROI
0m: 10000.0%
Interface Version
N/A
Startup Candles
N/A
Indicators
1
iterativv/NostalgiaForInfinity
davidzr/freqtrade-strategies
BB_RPB_TSL @author jilv220 Simple bollinger brand strategy inspired by this blog ( https://hacks-for-life.blogspot.com/2020/12/freqtrade-notes.html ) RPB, which stands for Real Pull Back, taken from ( https://github.com/GeorgeMurAlkh/freqtrade-stuff/blob/main/user_data/strategies/TheRealPullbackV2.py ) The trailing custom stoploss taken from BigZ04_TSL from Perkmeister ( modded by ilya ) I modified it to better suit my taste and added Hyperopt for this strategy.
davidzr/freqtrade-strategies
BB_RPB_TSL @author jilv220 Simple bollinger brand strategy inspired by this blog ( https://hacks-for-life.blogspot.com/2020/12/freqtrade-notes.html ) RPB, which stands for Real Pull Back, taken from ( https://github.com/GeorgeMurAlkh/freqtrade-stuff/blob/main/user_data/strategies/TheRealPullbackV2.py ) The trailing custom stoploss taken from BigZ04_TSL from Perkmeister ( modded by ilya ) I modified it to better suit my taste and added Hyperopt for this strategy.
from freqtrade.strategy.interface import IStrategy
from pandas import DataFrame
#from technical.indicators import accumulation_distribution
from technical.util import resample_to_interval, resampled_merge
import talib.abstract as ta
import freqtrade.vendor.qtpylib.indicators as qtpylib
import numpy
from technical.indicators import ichimoku
class Ichimoku_v23(IStrategy):
"""
"""
minimal_roi = {
"0": 100
}
stoploss = -1 #-0.35
ticker_interval = '4h' #3m
# startup_candle_count: int = 2
# trailing stoploss
#trailing_stop = True
#trailing_stop_positive = 0.40 #0.35
#trailing_stop_positive_offset = 0.50
#trailing_only_offset_is_reached = False
def informative_pairs(self):
return []
def populate_indicators(self, dataframe: DataFrame, metadata: dict) -> DataFrame:
ichi = ichimoku(dataframe, conversion_line_period=20, base_line_periods=60, laggin_span=120, displacement=30)
# dataframe['chikou_span'] = ichi['chikou_span']
dataframe['tenkan'] = ichi['tenkan_sen']
dataframe['kijun'] = ichi['kijun_sen']
dataframe['senkou_a'] = ichi['senkou_span_a']
dataframe['senkou_b'] = ichi['senkou_span_b']
dataframe['cloud_green'] = ichi['cloud_green']
dataframe['cloud_red'] = ichi['cloud_red']
return dataframe
def populate_buy_trend(self, dataframe: DataFrame, metadata: dict) -> DataFrame:
dataframe.loc[
(
(qtpylib.crossed_above(dataframe['close'], dataframe['senkou_a'])) &
(dataframe['close'] > dataframe['senkou_a']) &
(dataframe['close'] > dataframe['senkou_b']) &
(dataframe['close'] > dataframe['close'].shift(1)) &
(dataframe['close'].shift(1) > dataframe['close'].shift(2))
),
'buy'] = 1
dataframe.loc[
(
(qtpylib.crossed_above(dataframe['close'], dataframe['senkou_b'])) &
(dataframe['close'] > dataframe['senkou_a']) &
(dataframe['close'] > dataframe['senkou_b']) &
(dataframe['close'] > dataframe['close'].shift(1)) &
(dataframe['close'].shift(1) > dataframe['close'].shift(2))
),
'buy'] = 1
return dataframe
def populate_sell_trend(self, dataframe: DataFrame, metadata: dict) -> DataFrame:
dataframe.loc[
(
(qtpylib.crossed_below(dataframe['tenkan'], dataframe['kijun'])) &
(dataframe['close'] < dataframe['senkou_a']) &
(dataframe['close'] < dataframe['senkou_b']) &
(dataframe['cloud_red'] == True)
),
'sell'] = 1
return dataframe