The PiggyBack Expert Advisor is a fully automated trading system with an information and trading panel. It uses four selectable mathematical algorithms, which allow opening positions using both short-term scalping and long-term settings. The trade algorithm of the EA works separately for buy and sell positions. It can work on all timeframes starting with M1.
- Manual_Mode - mode of manual operation using two trade panels. It allows manually managing the order groups opened by the EA or performing full-fledged manual trading. The open orders are managed by the recovery grids of the PiggyBack_SmartGrids mode.
- Grids_Mode - indicator-less grid system. Trading begins with the opening of two orders in different directions, each of which is managed by a separate group of grids. When both groups are closed, two orders are opened again.
- PiggyBack_Standard - indicator-less grid system. Trading begins with the opening of two orders in different directions. When closed, two orders in different directions are opened again, with one of them increased by the Multiplier coefficient.
- PiggyBack_SmartGrids - trading begins with the opening of two orders in different directions. When the Buy order is closed, an algorithm is launched, which is guaranteed to open a Buy order, and a Sell order will only be opened when the group of indicators generates an according signal. Sell orders are opened similarly.
Trading panel of the EA
- Deposit load - shows the deposit load percentage.
- StopLevel - stop level of the selected instrument in points.
- Drawdown/Grown - drawdown/growth of the trade balance as a percentage.
- Spread Value - spread in points.
- In Deals - volume of open trades in lots.
- Close Buy - close all opened buy positions and buy pending orders on the selected instrument, if the Magic Number of the order matches, and displays the profit/loss of the opened buy orders in the deposit currency.
- Close Sell - close all opened sell positions and sell pending orders on the selected instrument, if the Magic Number of the order matches, and displays the profit/loss of the opened sell orders in the deposit currency.
- Close All - close all opened positions and pending orders on the selected instrument, if the Magic Number of the order matches, and displays the profit/loss of the opened orders in the deposit currency.
- Open Buy - send a Buy order and display the volume in lots for the next Buy order in the queue.
- Open Sell - send a Sell order and display the volume in lots for the next Sell order in the queue.
- TypeOfWork - select the EA operation mode.
- Lots - volume of the first trade in the group of orders, in lots.
- Magic - magic number.
- Step - step for the order grid in points.
- Multiplier - multiplier for orders.
- MaximumLotsValue - the maximum allowed volume of one order in lots.
- MaximumOrdersInWork - the maximum allowed number of orders opened by the Expert Advisor.
- TrailingStepEquity - step of the virtual trailing in the deposit currency.
- TrailingStartEquity - start of the virtual trailing in the deposit currency.
How to configure TrailingStop
TrailingStepEquity and TrailingStartEquity work in the deposit currency. TrailingStartEquity = 1.55 means that the trailing algorithm is launched when the profit of the order group is 1.55 units of the deposit currency. If we want to increase Lots, then TrailingStartEquity should also be modified in multiples or at least partially in multiples of Lots increase.
Since closing a group of orders in the PiggyBack_Standard and PiggyBack_SmartGrids modes causes new orders to be opened, a small value of TrailingStartEquity means a greater number of deals. It is useful for scalper strategies. On the other hand, a larger value reduces the number of the opened orders.
I recommend setting TrailingStepEquity to 1.5xLots or 2xLots.
Added buttons for opening orders.