Strategy: custom_stoploss_with_psar_215
Downloaded: 20220112
Stoploss: -0.2

Strategy failed backtesting!
Reason: Duplicate of TSIHULLBOT

You will be redirected to the original Strategy in 15 seconds.Redirecting...
The "CustomStoplossWithPSAR" strategy is an example class that implements a trailing stop loss based on the Parabolic SAR (PSAR) indicator. Here's a brief description of what the strategy does: Timeframe: The strategy operates on the 1-hour timeframe. Stoploss: The stoploss is set to -0.2, which means that if the current profit of a trade drops by 20%, the position will be sold.

Custom Info: The strategy maintains a dictionary called "custom_info" to store custom information for each trading pair.

Use Custom Stoploss: The strategy enables the use of a custom stoploss.

Custom Stoploss Function: The custom_stoploss() function calculates a new stoploss value based on the difference between the current rate and the Parabolic SAR indicator value. The result is a relative negative offset required by the return implementation of the custom_stoploss() function. Populate Indicators Function: The populate_indicators() function adds the Parabolic SAR indicator ("sar") to the dataframe. In backtesting or hyperopt mode, the function stores the SAR values in the "custom_info" dictionary for each trading pair. Populate Buy Trend Function: The populate_buy_trend() function generates a buy signal when the SAR value is smaller than the SAR value of the previous candle. It sets the "buy" column to 1 for the corresponding rows in the dataframe. Populate Sell Trend Function: The populate_sell_trend() function does nothing and keeps the "sell" column as 0, allowing the strategy to work correctly. This strategy demonstrates how to implement a custom stoploss using the PSAR indicator and how to generate buy signals based on the SAR values. You can adapt this strategy and modify the buy and sell conditions according to your own trading strategy requirements.

stoploss: -0.2
timeframe: 1h
hash(sha256): b36b8c6862592b1dab923a7fd4923480036502414adb3810150ef2d57c7ca1ba
date sar date sar

No similar strategies found. (based on used indicators)

last change: 2022-07-02 19:54:08