freqtrade - doubility-sky/daydayup GitHub Wiki

Freqtrade is a free and open source crypto trading bot written in Python. It is designed to support all major exchanges and be controlled via Telegram or webUI. It contains backtesting, plotting and money management tools as well as strategy optimization by machine learning.

Learn

blogs

Configuration

Strategies

examples

  • Example Strategies - Collection of strategies for Freqtrade
  • NostalgiaForInfinity - Trading strategy for the Freqtrade crypto bot. For backtesting results, check out the comments in the individual commit page.

Backtesting

  • Data Downloading - Obtaining historical data for backtesting
  • Assumptions made by backtesting
  • :warning:Backtest Traps
    • Trailing Stoploss
      • The bot mostly gonna check profit based of high value, then in case of a long green candle, you might exit near the high, especially if you set a very tight trailing.
      • FSD – Trailing stoploss
    • Custom Exit
      def custom_exit(self, pair: str, trade: Trade, current_time: datetime, current_rate: float, current_profit: float, **kwargs) -> Optional[Union[str, bool]]:
          dataframe, _ = self.dp.get_analyzed_dataframe(pair, self.timeframe)
          current_candle = dataframe.iloc[-1].squeeze()
          current_profit = trade.calc_profit_ratio(current_candle['close'])
      
      • The snippet above will make sure your current_profit tied to last closed candle’s close rate, ensuring that your backtesting results are consistent with live trading results.
      • FSD – Custom exit
    • ROI
      • Using time intervals that correspond to your timeframe will help you avoid falling into the ROI trap.
    • Backtest in batches
      • Can you avoid such issue while still doing backtest in batches? Sure, if your average trade duration is very short.
  • Improved backtest accuracy
  • Analyzing Results - Visualizing and analyzing backtest results

Control the Bot

FAQs

Resources