The Arbitrage Reverse Expert Advisor is an innovative script that trades based on the direction of the trend and the historical (average) trading price. It does not use any technical indicators, but performs trading decisions based on the current price, the current profit / loss, and the accumulated (historical) profit / loss of the trading account. The idea behind this Expert Advisor is that prices revert to the mean, so taking position in the anticipation that price will revert to the mean can lead to good profits.
The initial entry trigger price is calculated based upon the input BEGINPRICE and the average price of the closed (historical) trades of the current instrument. A LONG trade is initiated if the current price goes below this trigger price, whereas a SHORT trade is initiated if the current price goes above the trigger price. To avoid entering too many consecutive trades in the same direction and risk losing money, the Expert Advisor executes the trades only once per candle. This reduces the risk of opening too many trades too quickly and conserving margin.
The trigger price is recalculated on each candle – if the current price is still below the new trigger price, the Expert Advisor opens another LONG trade with an increased lot size. On the other hand, if the current price is above the new trigger price, the Expert Advisor opens a new SHORT trade if none exists. However, if a SHORT trade already exists, it closes a matching LONG and a SHORT trade such that their net profit is positive. This ensures that the Expert Advisor reduces its margin exposure as well as taking profits at regular intervals. If it cannot find a matching LONG and SHORT trade whose combined profit is positive it opens a new SHORT trade. This process is repeated until the price moves to the opposite side of the trigger price thereby closing matching profitable positions.
The Arbitrage Reverse Expert can be very profitable in range bound markets, and in markets where a trend reversal is imminent. In range bound markets, the Expert Advisor takes positions when the price moves away from the trigger price, and then closes profitable positions as the price approaches the trigger price. In such markets, the price typically oscillates around the trigger price thus providing excellent trading opportunities.
In markets where trend reversal is imminent, the Expert Advisor initially takes positions in the opposite direction of the current trend. This is because the Expert Advisor opens LONG trades below the trigger price, and SHORT trades above the trigger price. When a reversal occurs the Expert Advisor turns profitable and closes the profitable positions in pairs.
Once all positions are closed, the Expert Advisor starts again by recalculate the new trigger price.
Configurable Inputs for Arbitrage Reverse Expert Advisor
- EXPERTS– The number of instruments (charts) on which the Expert Advisor is run concurrently. This Expert Advisorcan identify arbitrage opportunities, and hence can work concurrently on more than on instrument. It is used to determine the lot-size allocation for placing the trades. If the Expert Advisoris active on more than one instrument, the lot-size is scaled down accordingly. For example, if this Expert Advisor is used to trade the arbitrage of EURUSD and USDJPY, then this parameter is set to 2. If this Expert Advisoris used to trade only one (current) instrument, then this parameter is set to 1.
- BEGINPRICE –The initial price at which the Expert Advisorstarts opening the trades. When the price touches (or crosses) this parameter, the Expert Advisorstarts placing the trades.