The Moving Average Cross Expert Advisor is a classic trend Expert Advisor. It works on a real account of any broker with any order execution method. It is resistant to connection errors, controls the margin, preventing the deposit from being “overloaded” when working with other Expert Advisors. The Expert Advisor also has built – in capabilities for trading on the Martingale principle.
Moving Average Cross is based on the following idea:
The intersection of two moving average lines (fast and slow) as a signal for opening and closing a position, plus additional functions to improve the efficiency of the vending machine.
The main advantages of the trend trading strategy that the Expert Advisor uses are, firstly, opening a position exclusively in the direction of the trend, secondly, the possibility of long-term retention of profitable positions, which allows you to get a good combination of profit/loss distributions, and thirdly, simplicity and clarity when setting up and testing the system.
The Expert Advisor enters the market at the moment of opening the next signal candle after it. The signal candle is the candle on which the signal for entering the market was fixed.
Signal to enter the market:
[spoiler title=”Read More…”]
- BUY: The fast MA crosses the slow MA from the bottom up.
- SELL: The fast MA crosses the slow MA from top to bottom.
When opening a trade, you can set the Take Profit and Stop Loss values. If these values are less than the values allowed by the broker, the Expert Advisor will set them automatically.
If the Close by MACross function is enabled, the EA exits the market at the moment of opening the next candle after the signal one. A signal candle is the candle on which the signal to exit the market was fixed.
Signal to exit the market:
- BUY: The fast MA crosses the slow MA from top to bottom.
- SELL: The fast MA crosses the slow MA from bottom to top.
The operation can also be closed manually or by a pre-set Take Profit or Stop Loss.
- Lot – the lot that the EA will trade.
- Stop_Loss – the Stop Loss value in points for the position.
- Take_Profit – the value of the Take Profit in points for the position.
- Fast_MA – the period for calculating the fast moving average.
- Slow_MA – the period for calculating the slow moving average.
- MA_Ture – method for calculating moving averages (0-Simple, 1-Exponential, 2-Smoothed, 3-Linear Weighted).
- Close_Posicion_Via_MACross-enable (true) or disable (false) the EA function – close positions at the intersection of averages.
- Stop_To_Zero_Function-enabling (true) or disabling (false) the EA function – transferring the Stop Loss to the break-even level.
- Stop_To_Zero_Level – the value in points when the EA moves the Stop Loss to breakeven. If the parameter value is less than the Stop Loss level allowed by the system, the Expert Advisor will set the value of the specified parameter automatically.
- Tral_Function-enable (true) or disable (false) the Expert Advisor function – Trailing Stop.
- Tral_Level – the profit level in points, after which the Trailing Stop will work.
- Tral_Step – the value in points at which the Expert Advisor will track the Stop Loss. If the parameter value is less than 10 points for instruments with an accuracy of 5 decimal places, and 5 points for other instruments, the Expert Advisor will set the parameter value to 10 or 5 points, respectively.
- Voice_signal-enables (true) or disables (false) the function of the Expert Advisor – by sound notification when opening and closing positions by the Expert Advisor.
- Margin_Control-enables (true) or disables (false) the function of the Expert Advisor – to control the percentage of funds used in trading.
- Max_Persent_Depo – the percentage of funds (deposit percentage) that will be used in trading. The recommended value is 5-10% (and less than 100%).
- Martin_Function-enable (true) or disable (false) the EA function – use the variable volume for trading. (In the case of a losing trade, the next one will be opened with a large lot by multiplying the previous volume by the lot increase factor).
- Martin_Koef – the coefficient of increasing the lot when trading with a variable volume.
- Max_Lot – the maximum size of a trading position when trading with a variable volume.
- iMagicNumber – the unique number of the Trading Advisor. The system sets the number based on the time interval.