The strategy, called SMAOffsetMod1BTC, is a backtesting strategy for trading cryptocurrencies. It uses a combination of simple moving averages (SMA) and offsets to generate buy and sell signals. Here's a breakdown of how the strategy works:
Timeframe: The strategy operates on 5-minute candlestick data.
Indicator Calculation: The strategy calculates various moving averages for the chosen cryptocurrency pair and timeframe.
It uses both the current pair's candlestick data and an informative pair (BTC/USDT on a 5-minute timeframe) to calculate the moving averages.
The informative pair data is merged with the current pair data. Buy Signal: The strategy generates a buy signal when the following conditions are met:
The closing price is lower than the 30-period simple moving average (SMA) multiplied by a low offset. The 2-period SMA is lower than the closing price. The 3-period SMA is lower than the 2-period SMA. The 35-period SMA is lower than the 5-period SMA. The trading volume is higher than 40,000. Sell Signal: The strategy generates a sell signal when the following conditions are met:
The closing price is higher than the 30-period SMA multiplied by a high offset. The 2-period SMA is higher than the closing price. The 3-period SMA is higher than the 2-period SMA. The trading volume is higher than 40,000. Risk Management:
Stop Loss: The strategy sets a fixed stop loss at -12%. Trailing Stop: The strategy uses a trailing stop with a positive offset of 1% and a positive offset offset of 12%. Sell Profit Only: The strategy sells only when a profit of 1% or more can be achieved. Ignore ROI if Buy Signal: The strategy ignores the predefined ROI table if a buy signal is present. Other Configuration:
Candle Count: The strategy requires 60 candles before producing valid signals. Order Types: The strategy uses market orders for buying, selling, and stop loss. Order Time in Force: The order time in force is set to "good till canceled" (gtc). Plot Configuration: The strategy defines the plot configuration for visualizing various indicators. Please note that this is a simplified description of the strategy. The actual implementation may involve additional details and considerations.
Traceback (most recent call last):
File "/freqtrade/freqtrade/main.py", line 42, in main
return_code = args['func'](args)
^^^^^^^^^^^^^^^^^^
File "/freqtrade/freqtrade/commands/optimize_commands.py", line 58, in start_backtesting
backtesting.start()
File "/freqtrade/freqtrade/optimize/backtesting.py", line 1401, in start
min_date, max_date = self.backtest_one_strategy(strat, data, timerange)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/freqtrade/freqtrade/optimize/backtesting.py", line 1318, in backtest_one_strategy
preprocessed = self.strategy.advise_all_indicators(data)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/freqtrade/freqtrade/strategy/interface.py", line 1378, in advise_all_indicators
return {pair: self.advise_indicators(pair_data.copy(), {'pair': pair}).copy()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/freqtrade/freqtrade/strategy/interface.py", line 1378, in
return {pair: self.advise_indicators(pair_data.copy(), {'pair': pair}).copy()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/freqtrade/freqtrade/strategy/interface.py", line 1410, in advise_indicators
return self.populate_indicators(dataframe, metadata)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/freqtrade/user_data/strategies/Discord_SMAOffsetMod1BTC.py", line 90, in populate_indicators
dataframe = merge_informative_pair(dataframe, informative, self.timeframe, ffill=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: merge_informative_pair() missing 1 required positional argument: 'timeframe_inf'