Termos de Referência
HEDGING STRETEGY OVERVIEW/CONCEPT
Randomly enter a BUY trade with a Lot size of 0.01 when there is no open trade in the market and a SELL pending order with TRIPLE the Lot size, 30 pips below the BUY trade.
Both trades should have a stoploss of 60 pips and a Take Profit of 30 pips.
For all pending orders triggered, an opposite pending order should be entered 30 pips away from the last position, with DOUBLE the lot size of the recent opened trade.
THE ISSUES TO FIX:
- Correct EA to Close all open and pending orders when TP or SL triggered.
- Ea sometimes fail to open new pending order.
- Check the logic
SETTINGS (NOTE: ALL PARAMETERS SHOULD BE ADJUSTABLE)
Parameter | Options | Description |
First trade direction | BUY/SELL | Add option to choose the first trade direction |
Initial Lot size | Number | Lot size for first trade |
Lot multiplier (1) | Number | Multiplier for the first pending order |
Lot multiplier (2) | Number | Multiplier for other pending orders |
Hedge Range/Distance | Points | The distance between the last trade and the opposite pending order |
Stop loss | Points | Stop loss in points |
Take profit | Points | Take profit in points |
Magic TP/SL | YES (Automatic default) | EA to close all open trades including pending orders when a SL or TP is triggered. |
Repeat first trade | ON/OFF | If ON, EA will pause trading after SL or TP is triggered and all orders are closed.
If OFF, EA will open new market order with initial lot size and repeat the hedging circle again. |
Pause Trading | ON/OFF | EA opens trades only when this is OFF. |
https://drive.google.com/file/d/1hjufvXYk4ZwIwRBBkiWry_BiyBx-XZKj/view?usp=drive_link