• Overview
  • Reviews (3)
  • Comments (29)
  • What's new

Moving average Freestyle

Moving Average Freestyle is an EA based on moving averages “All-in-One”. Many possible combinations can be configured, from a strategy with a simple average, to crossing of 2 or 3 moving averages with filters with RSI, MACD or ADX.

How It Works?

We can choose what type of strategy we use.

  • Price vs Moving Average: When the price crosses the MA, the order is activated (buy code: "P>A" sell code: "P <A").
  • Crossing two Moving Averages: When the fast MA crosses the slow MA, the order is activated (buy code: "A>B" sell code: "A<B").
  • Crossing three Moving Averages: When the fast MA has crossed the other two slower MA's in the same direction, the order is activated (buy code: "A>B>C" sell code: "A<B<C").


  • RSI filter: It’s used to avoid entering orders to market in excess of overbought or oversold. It can also be used with reverse mode.
  • MACD Filter: With MACD we have a trend filter that helps us to improve the signals. It can also be used in reverse for contrarian trading.
  • ADX Filter: The ADX is another trend filter that helps us improve the signal. Through the ADX you can filter by the strength of the trend.

Additional Configuration

  • Period and MA type: You can set the period and MA type of each.
  • Close when reverse condition (True / False): When True, if we have opened a buy and then we have a sell signal, then the EA closes buy (same for the opposite direction).
  • Stop Loss, Take Profit, BreakEven and TrailingStop: You can also put Take Profit and Stop Loss on Pips, as well as BreakEven and TrailingStop. If the value in these parameters is 0, then the parameters will be disabled.

Coding of the conditions of buys:

  • "P> A": When Price > MA A.
  • "A>B": When MA A> MA B.
  • "A>B>C": When MA A> MA B and MA B> MA C.

Coding of conditions of sells:

  • "P<A": When Price < MA A.
  • "A<B": When MA A < MA B.
  • "A<B<C": When MA A < MA B and MA B <MA C.


  • Moving Average A period: Period of fast MA.
  • Moving Average B period: Period of middle MA.
  • Moving Average C period: Period of slow MA.
  • Moving Av. A Type: MA Type A.
  • Moving Av. B Type: MA Type B.
  • Moving Av. C Type: MA Type C.
  • Condition_buy: condition for buy ("P> A" or "A> B" or "A> B> C").
  • Condition_sell: condition for sell ("P <A" or "A <B" or "A <B <C").
  • Entry_Only_When_Cross: true: the signal occurs only at the time the crossover occurs; False: the signal is produced if the price or average is greater or less, regardless of the moment.
  • Close Order when reverse condition: If a signal occurs and there is an opened order of the opposite sign, it is closed.
  • Wait_until_close: true: Wait for the closing of the candle to validate signal, deactivated instantaneously validates signal.
  • Lot_size: Volume size.
  • use_lot_ratio: Enable/Disable lot_ratio to use martingala
  • lot_ratio: Lot ratio in your Account Balance for every 0.01 lots.
  • drawdown_control: Enable/Disable Drawdown Control.
  • drawdown_each_percent: drawdown percentage to reduce lotsize.
  • drawdown_reduction_ratio: Ratio to reduce lotsize for every drawdown percentage loss (ratio 2 is 50% less).
  • Stop Loss Pips: stop loss pips.
  • Break Even Pips: pips for BreakEven.
  • Trailing Stop Pips: pips for trailing.
  • Magic Number: Magic number.
  • Enable_RSI_filter: Enable RSI filter
  • RSI_buy_value: RSI value for buy.
  • RSI_sell_value: RSI value for sell.
  • RSI_BuyAbove / SellBelow: The RSI value must be above the RSI level set for buy, and below the RSI level for sell. If false, it works reverse.
  • RSI_period: RSI period.
  • RSI_Timefrime: RSI Timefrime.
  • Enable_MACD_filter: Enable MACD filter
  • MACD_buy_value: MACD level for buy.
  • MACD_sell_value: MACD level for sell.
  • MACD_BuyAbove / SellBelow: The MACD value must be above the MACD level set for buy, and below the MACD level for sell. If false, it works reverse.
  • MACD_Timefrime: MACD Timefrime.
  • Enable_ADX_filter: Enable or Disable the ADX filter
  • Enable_ADX_direction_filter: The direction of DI + and DI- is required to be with trend favor signal.
  • ADX_buy_value: ADX level for buy.
  • ADX_sell_value: ADX level for sell.
  • ADX_period: ADX period.
  • ADX_Timefrime: ADX Timefrime.
  • use_ADX_reduction_exit: Enable/Disable an exit rule when ADX decreases.
  • ADX_reduction_ratio: ADX reduction percentage to close order.
Jesús Torres
Jesús Torres 2017.11.12 15:31 

The EA has several errors. There are problems when optimizing the EMA of the indicators, and the SL does not act sometimes.

It needs to be corrected.


When reading it does not work well, some things do not work as you say, the SL skips it, some of the optimizations of the indicators simply do nothing.

The programmer that I have contacted comments that he does not have time to fix it, but to do EA for other people.

EA denounced in MQL. If you fix it, I will change my score as it deserves.

Xicod 2017.09.09 23:59 

Gracias Cristian,

Has desarrollado un muy buen EA, muy completo y todo muy fácil de entender a la hora de parametrizar.

A parte de poder usar varias medias tiene la opción de combinarlo con uno o varios indicadores me interesa mucho la forma que tines varios sistemas en un solo EA.

Lo dicho

Muchas Gracias

Ugo Della Rocca
Ugo Della Rocca 2017.06.08 16:45 

The program does not follow the opening rules in the sets ... in particular it opens even if the cross is not real (also activating the option in the sets) and closes the positions when a reverse crossover occurs (although in the set this rule Is disabled) ... the developer has refused to correct these errors

Version 1.21 2017.04.27
Improvement in Stop Loss
Version 1.20 2017.02.14
- We incorporate parameters for the selection of period and timefrimes in the filters indicators (RSI, MACD and ADX).
- New optional exit rule using ADX reduction (very effective!).
Version 1.10 2017.01.18
- New parameter to allow only 1 order at the same time.
- Money Management parameters.
- Drawdown Control parameters.