Improve documentation.

This commit is contained in:
Reigo Reinmets 2021-12-21 00:11:01 +02:00
parent c9243fb4f6
commit 4862cdb296
2 changed files with 6 additions and 6 deletions

View File

@ -233,13 +233,14 @@ merged_frame = pd.concat(frames, axis=1)
## Adjust trade position ## Adjust trade position
`adjust_trade_position()` can be used to perform additional orders to manage risk with DCA (Dollar Cost Averaging) for example. `adjust_trade_position()` can be used to perform additional orders to manage risk with DCA (Dollar Cost Averaging) for example.
The strategy is expected to return a stake_amount if and when an additional buy order should be made (position is increased).
If there is not enough funds in the wallet then nothing will happen.
Additional orders also mean additional fees and those orders don't count towards `max_open_trades`.
Unlimited stake amount with trade position increasing is highly not recommended as your DCA orders would compete with your normal trade open orders.
!!! Note !!! Note
The `position_adjustment_enable` configuration parameter must be enabled to use adjust_trade_position callback in strategy. The `position_adjustment_enable` configuration parameter must be enabled to use adjust_trade_position callback in strategy.
!!! Warning
Additional orders also mean additional fees.
!!! Warning !!! Warning
Stoploss is still calculated from the initial opening price, not averaged price. Stoploss is still calculated from the initial opening price, not averaged price.

View File

@ -575,6 +575,8 @@ class AwesomeStrategy(IStrategy):
`adjust_trade_position()` can be used to perform additional orders to manage risk with DCA (Dollar Cost Averaging). `adjust_trade_position()` can be used to perform additional orders to manage risk with DCA (Dollar Cost Averaging).
The strategy is expected to return a stake_amount if and when an additional buy order should be made (position is increased). The strategy is expected to return a stake_amount if and when an additional buy order should be made (position is increased).
If there is not enough funds in the wallet then nothing will happen. If there is not enough funds in the wallet then nothing will happen.
Additional orders also mean additional fees and those orders don't count towards `max_open_trades`.
Unlimited stake amount with trade position increasing is highly not recommended as your DCA orders would compete with your normal trade open orders.
!!! Note !!! Note
Current implementation does not support decreasing position size with partial sales! Current implementation does not support decreasing position size with partial sales!
@ -582,9 +584,6 @@ If there is not enough funds in the wallet then nothing will happen.
!!! Tip !!! Tip
The `position_adjustment_enable` configuration parameter must be enabled to use adjust_trade_position callback in strategy. The `position_adjustment_enable` configuration parameter must be enabled to use adjust_trade_position callback in strategy.
!!! Warning
Additional orders also mean additional fees.
!!! Warning !!! Warning
Stoploss is still calculated from the initial opening price, not averaged price. Stoploss is still calculated from the initial opening price, not averaged price.
So if you do 3 additional buys at -7% and have a stoploss at -10% then you will most likely trigger stoploss while the UI will be showing you an average profit of -3%. So if you do 3 additional buys at -7% and have a stoploss at -10% then you will most likely trigger stoploss while the UI will be showing you an average profit of -3%.