Mastering Freeman: Your Go-To EA for MetaTrader 5

Mike 2018.10.26 03:27 23 0 0
Attachments

The Brain Behind the Idea - vgs

Code Wizard - barabashkakvn

IMPORTANT: Use only for hedge accounts! Netting is not allowed!

Freeman utilizes dynamic stop loss and take profit settings, calculated via the iATR (Average True Range) indicator. The value from bar #0 is multiplied by the specified Stop Loss and Take Profit ratios to determine your levels.

For traders with multiple open positions and no locking orders, there's a chance to average down:

  • If you have a BUY position and the current Ask price dips below your entry point by the specified Distance, you can open another BUY position.
  • If you have a SELL position and the current Bid price rises above your entry point by the specified Distance, you can open another SELL position.

Distance is standardized for four-digit currency pairs.

You can set your position volume in two ways:

  • Fixed volume - If the Lots parameter is greater than 0.0 and Risk is set to 0.0, the Lots parameter will dictate your position size.
  • Dynamic volume - If the Lots parameter is 0.0 and Risk is greater than 0.0, the Risk parameter will define your risk per trade.

Freeman's trailing feature adjusts your stop loss to break even after the first modification and continues to trail for subsequent adjustments. The Trailing Stop sets the minimum gap from the price to the stop loss, while the Trailing Step determines the trailing increment. Both parameters are standardized for four-digit pairs.

The Bars Control parameter indicates the EA's operation: it can trigger on the occurrence of a new bar only (true) or operate within a bar (false).

Generating Trading Signals

The primary parameter for trading signals is the Current Bar.

Trend Filter

The trend filter assesses the iMA (Moving Average) value of the current bar against that of the previous bar. For a BUY signal, the MA should be below the price; for a SELL signal, the MA should be above the price.

RSI Filter

The RSI filter compares the iRSI (Relative Strength Index) value on the current bar with the defined RSI level UP and RSI level DOWN. For a SELL signal, RSI should exceed the RSI level UP, while for a BUY signal, it should fall below the RSI level DOWN.

Locking Positions

If you have an open position and the last closed position of the same type resulted in a loss, it’s time to consider locking. Here’s how:

  • If you have a BUY position and the previous BUY closed at a loss, and the current Ask price is at least Distance away from that position, you can open another BUY.
  • If you have a SELL position and the previous SELL closed at a loss, and the current Bid price is at least Distance away from that position, you can open another SELL.

The detection of position closing moments occurs in OnTradeTransaction.

Example: EURUSD, M15:

freeman

List
Comments 0