The "donchian" strategy is a trading strategy implemented in the backtesting website. It uses the donchian channel indicator to generate buy and sell signals based on price breakouts. Here's a breakdown of the important parts of the strategy:
Minimal ROI: This parameter defines the minimum return on investment (ROI) that the strategy aims to achieve.
It is not specified in the given code snippet.
Stoploss: This parameter sets the optimal stop-loss level for the strategy.
If the price moves against the position by a certain percentage (in this case, 10%), the position is automatically closed to limit losses. Ticker Interval: This parameter determines the interval at which the strategy analyzes price data. In this case, it's set to '1h', meaning the strategy operates on hourly price data. Order Types: This mapping defines the order types for different trading actions. In this strategy, all orders (buy, sell, and stop-loss) are set as 'market' orders, which execute at the current market price. Order Time in Force: This parameter sets the time in force for the orders. The 'gtc' (good 'til canceled) value means the orders remain active until executed or manually canceled. The strategy uses the following indicators from the TA-Lib library and Freqtrade's vendor library:
Maximum (MAX): Calculates the highest value over a given period (upperlength) and assigns it to the 'max' column in the dataframe. Minimum (MIN): Calculates the lowest value over a given period (upperlength) and assigns it to the 'min' column in the dataframe. The 'upper' and 'lower' columns in the dataframe are the previous period's maximum and minimum values, respectively. The 'middle' column represents the middle point between the 'min' and 'max' values. The 'populate_buy_trend' function generates buy signals when the closing price crosses above the 'upper' value. The 'populate_sell_trend' function generates sell signals when the closing price crosses below the 'lower' value. Overall, the strategy aims to capture potential price breakouts by buying when the price exceeds the upper channel and selling when it falls below the lower channel.