TrailMe
TrailMe is a group of features that allows you to trail different types of trades to reach better entry or exit points. This page describes all available configuration options.
Trailing works just like it does for the TSSL strategy, the difference being the starting point of trailing.
Orders resulting from trailing are only placed when the main strategy criteria are met, and confirming indicators (if any) allow the order. All these conditions must occur in the same cycle.
Trailing is an important concept in Gunbot. When buying, it allows for aiming for a lower entry price than strategy criteria would otherwise realize. When selling, it allows for higher profits, while locking in profits while trailing ranges move upwards along with price.
Basic principles​
- Trailing is purely based on prices, not on indicators.
- When confirming indicators are used, trailing must finish while their conditions are still met.
- When buying, the ask price is used as reference. When selling, bid is used.
- Ranges for trailing are defined as a percentage of the best bid or ask price. Bid is used when selling, ask is used when buying.
- When price moves in the direction of your target, ranges are set around bid/ask every round.
- When price moves in the opposite direction of your target, trailing limits are frozen.
- Ranges are reset when price moves outside of the target.
Buy trailing​
The same basic process applies for most kinds of buy trailing (exception: Take Buy). The example below shows how trailing works for buying with the tssl strategy.
When trailing with tssl, the most important part to know is that trailing must finish below Buy Level. Make sure to set a Buy Level that leaves enough room for trailing.
Other types of buy trailing, like DU trailing, follow the exact same trailing logic, but the threshold below which trailing must finish is different.
Type of trailing | Must finish below / while |
---|---|
TrailMe Buy | While other strategy buy criteria are met |
TrailMe DU | Below DU Buydown |
TrailMe RT Buy | Below RT Buy Level |
Tssl | Below Buy Level, while other strategy buy criteria are met |
Sell trailing​
The same basic process applies for most kinds of sell trailing (exception: Take Profit). The example below shows how trailing works for selling with the tssl strategy.
This example looks more complicated than the buy example above, because the concept of resetting trailing limits is now visualized.
Important to know about sell trailing with tssl is that the StopLoss limit must be above your setting for gain before trailing can finish. Make sure that you leave enough room for this to happen, either by setting a modest gain, or by using a small sell range.
TrailMe settings​
Label | Config Parameter | Default Value | Detailed Description |
---|---|---|---|
TrailMe buy | TRAIL_ME_BUY | false | Enables tssl-style trailing for buy orders once the normal strategy's buy criteria are met. This feature allows you to potentially capture more favorable prices as they fluctuate. |
TrailMe DU | TRAIL_ME_DU | false | When enabled, applies tssl-style trailing to double up (DU) orders, aiming to improve the entry price for these cost-averaging buys. |
TrailMe buy range | TRAIL_ME_BUY_RANGE | 0.5 | Sets the percentage range for the trailing buy feature. The bot will only place a buy order if the price falls within this range, helping to optimize entry points. |
TrailMe sell | TRAIL_ME_SELL | false | Enables tssl-style trailing for sell orders after the strategy's normal sell criteria are met, allowing for potentially better exit prices during price fluctuations. |
TrailMe sell range | TRAIL_ME_SELL_RANGE | 0.5 | This setting defines the trailing range as a percentage for sell orders. It allows the bot to delay selling until the price is within this specified range above the trigger price. |
TrailMe RT buy | TRAIL_ME_RT | false | Activates tssl-style trailing for RT_BUY orders, enhancing the reversal trading strategy by optimizing the buy-back price after a sell order. |
TrailMe RT sell range | TRAIL_ME_RT_SELL_RANGE | 0.5 | Configures the trailing range for RT_SELL orders. The bot aims to achieve a higher sell price by waiting for a rise within this percentage range after the initial trigger. |
RT sell up | RT_SELL_UP | 0.3 | Sets the starting point for trailing up an RT_SELL order, allowing you to adjust the price level from which trailing begins. This feature is only active when TM_RT_SELL is enabled. |
RT buy level | RT_BUY_LEVEL | 2 | Specifies the percentage drop in price after an RT_SELL that must occur to trigger an RT_BUY. This setting helps determine when to re-enter the market at a lower price, aiming to capitalize on market dips. |
Overview of effects on different order types​
Config Parameter | Affected Order Types | Not Affected Order Types |
---|---|---|
Trail Me Buy | Strategy buy | RT buy, Strategy sell, Close, DCA buy, Stop limit, RT buyback, RT sell |
Trail Me Sell | Strategy sell | RT buy, Strategy buy, Close, DCA buy, Stop limit, RT buyback, RT sell |
Trail Me DU | DCA buy | RT buy, Strategy sell, Close, Strategy buy, Stop limit, RT buyback, RT sell |
Trail Me RT | RT buy | Strategy buy, Strategy sell, Close, DCA buy, Stop limit, RT buyback, RT sell |
Trail Me RT Sell | RT sell | Strategy buy, Strategy sell, Close, DCA buy, Stop limit, RT buyback, RT buy |
Trail Me Buy Range | Strategy buy, RT Buy, DCA buy | Strategy sell, RT sell, Close, Stop limit, RT buyback |
Trail Me Sell Range | Strategy sell | Strategy buy, RT buy, Close, DCA buy, Stop limit, RT buyback, RT sell |
Trail Me RT Sell Range | RT sell | Strategy buy, Strategy sell, Close, DCA buy, Stop limit, RT buyback, RT buy |