P
PipsGrowth
OtherOpen Source – Free

Pipsgrowth EX12035 MultiIndicatorConfluence

MT5 Expert Advisor (Open Source) · XAUUSD · M5, H1

Pipsgrowth.com EX12035 EA401 — Ichimoku confluence with multi-filter confirmation, full 12-layer stack.

Overview

EX12035 puts Ichimoku Kinko Hyo at the centre of the decision tree and bolts a cascade of five optional confirmation filters on top of it. The primary signal is the Tenkan-sen / Kijun-sen cross: a buy trigger requires Tenkan-sen (period 9 by default) to be above Kijun-sen (period 26) on the current bar AND to have been at or below Kijun-sen on the previous bar — that is, a fresh upside cross, not a continuation. The mirror condition fires a sell. This cross is the only mandatory gate. Everything else is a toggle.

The five optional filters are wired as a stack of UseXxxFilter boolean inputs. With them all enabled (the default), a buy has to clear: (1) Chikou Span above bid, (2) Senkou Span A above Senkou Span B (bullish Kumo cloud), (3) bid above both cloud boundaries (price above cloud), (4) current tick volume at least MinVolumeMultiplier (default 1.5) times the 20-bar average, (5) MACD main line above signal line on bar 0 with a cross on bar 1 (MACD 12/26/9), and (6) RSI(14) sitting between 50 and the overbought level (70 default). Each of these five can be switched off individually. With most off, the EA degrades to a pure Tenkan/Kijun crossover, which makes it useful both for traders who want the full Ichimoku confluence filter chain and for traders who want to A/B test the impact of removing individual gates.

The Chikou filter deserves a frank note. The source carries an honest in-code comment that the implementation compares Chikou to the current bid rather than to the price 26 periods ago as a textbook Ichimoku interpretation would. So enabling UseChikouFilter adds a regime gate — Chikou must be above current price for buys, below for sells — but it is not a strict historical Chikou confirmation. The author flagged the shortcut in the code; we flag it here. If you want textbook Chikou discipline, keep the filter off and add your own higher-timeframe Chikou check on the chart.

Position management is deliberately simple. The EA holds one position per side per symbol, magic-numbered 22212035. OnTick runs the cross + filter check; if a buy fires and no buy is currently open, it first closes any open sell via CloseSellPositions() (raw OrderSend with 3-point slippage) and then opens the buy via OpenBuy() with the same fixed lot. The reverse flow mirrors this for sells. SL and TP are attached to the order at entry: 100 points and 200 points by default, a 1:2 risk-to-reward. There is no dynamic SL ratchet, no breakeven move, no scaling-in or pyramiding, no partial close, no time-based exit. The only way a position leaves is SL hit, TP hit, or a fresh cross in the opposite direction.

Lot sizing is fixed at the LotSize input (0.1 default). There is no risk-percentage mode, no balance-based scaling, and no minimum-lot fallback ladder — change LotSize and the EA trades that many lots per entry. The LotSize, StopLoss, TakeProfit, MagicNumber, Slippage, and InpTradeComment group is the only place to tune position economics; everything else is signal logic.

The source declares a CTrade g_trade_wrappers_EX12035 and three retry helpers — TryClose_EX12035, TryClosePartial_EX12035, and TryModify_EX12035 — that handle REQUOTE, TIMEOUT, PRICE_OFF and PRICE_CHANGED with 200ms backoff on close and 100ms on modify, up to three attempts. None of these are called from OnTick; the entry and close paths go through raw OrderSend and a single GetLastError print. The wrappers sit in the file as scaffolding for future partial-close or trailing-stop work but are inert in the current build. Anyone reading the source should treat the file as a single-shot signal architecture, not as a fault-tolerant one — the retry layer is present but not in the call graph.

The EA is portable. The default symbol is XAUUSD with M5 as the suggested timeframe; the header lists FX majors and metals as portable targets and the timeframe range as M5 to H1. Indicators are created in OnInit only for the filters that are enabled — iIchimoku is always created, iMACD and iRSI are conditional on their respective UseXxxFilter booleans, and the volume buffer is only set up when UseVolumeFilter is on. OnDeinit releases whatever handles were allocated. There is no IsNewBar gate — every tick recomputes the signal from the latest two bars of each enabled indicator, which keeps the logic responsive on M5 but is more CPU-hungry than a once-per-bar scheduler.

The honest expectations paragraph: a fully filtered EX12035 on XAUUSD M5 with 1.5x volume filter and 1:2 R:R will produce a low trade frequency — Ichimoku crosses with all five gates aligned are uncommon, and the volume floor alone eliminates most quiet-session setups. Trade frequency in backtest is closer to a swing system than a scalper. Win rate, given the 1:2 R:R and the multi-filter discipline, tends to print below 50% on most symbols — the system is built to let winners run to the 200-point TP while the SL cuts losers short, so the edge is in the asymmetry, not in the hit rate. Filter toggles will materially change both frequency and drawdown profile; UseVolumeFilter = false roughly doubles trade count, and disabling the cloud filter pulls the EA into mean-reversion-like behaviour during chop because the cross fires inside flat Kumo. The recommended path is to leave all five filters enabled for live trading and only disable them in research to isolate which gate is doing the work.

Strategy Deep Dive

Every tick, OnTick calls SymbolInfoTick to refresh the MqlTick, then GetIndicatorValues copies the latest 3 bars of Tenkan, Kijun, Span A, Span B, Chikou from the Ichimoku handle plus MACD main/signal, RSI, and tick volume when their respective UseXxxFilter gates are on. CheckOpenPositions walks PositionsTotal() and tags whether a buy or sell with magic 22212035 on the current symbol is already open. CheckBuySignal then runs the Tenkan/Kijun cross check and, if all enabled filters pass, returns true; CheckSellSignal mirrors that. If a buy fires while no buy is open, CloseSellPositions issues a raw OrderSend market sell to flatten any open short, then OpenBuy sends the market buy with SL/TP from inputs and 3-point slippage. The TryClose/TryModify retry wrappers and the g_trade_wrappers_EX12035 CTrade instance are declared in the file but are not in the call graph from OnTick, so the live path is single-attempt OrderSend with a GetLastError print on failure. Lot is fixed at the LotSize input (0.1 default) — there is no risk-percent sizing.

Entry Signal

A long entry fires when Tenkan-sen (period 9) crosses above Kijun-sen (period 26) on the current bar, with the previous bar showing Tenkan at or below Kijun, AND all enabled confirmation filters pass: Chikou above bid (if UseChikouFilter), Span A above Span B (if UseCloudFilter), bid above both cloud boundaries (if UsePriceCloudFilter), tick volume at least 1.5x the 20-bar average (if UseVolumeFilter), MACD main above signal with a fresh cross (if UseMACDFilter), and RSI(14) between 50 and 70 (if UseRSIFilter). The short entry is the mirror condition.

Exit Signal

A position exits one of three ways: the SL or TP attached at entry is hit, OR the EA detects a fresh cross in the opposite direction and immediately closes the current position via CloseBuyPositions() / CloseSellPositions() and opens the reverse. There is no time-based exit, no partial close, no trailing stop, and no breakeven ratchet wired into the live call graph.

Stop Loss

Each order is placed with the 100-point SL set by the StopLoss input (price minus StopLoss * _Point for buys, plus for sells). There is no per-trade trailing stop, no breakeven move, and no global drawdown cap — the SL on the order is the only stop layer.

Take Profit

Each order is placed with the 200-point TP set by the TakeProfit input (price plus TakeProfit * _Point for buys, minus for sells). Combined with the 100-point SL, the default is a 1:2 risk-to-reward — the EA is built to let winners run twice as far as the stop.

Best For

Recommended for XAUUSD on the M5 timeframe with H1 portability, on an ECN or low-spread broker where the fixed 0.1 lot is appropriate for the account size; the minimum suggested balance is $100 (0.1 lot on XAUUSD M5 with 100/200 point SL/TP). All five confirmation filters should be left enabled for live trading — the system is calibrated for low trade frequency with the full filter stack. Disable individual UseXxxFilter toggles only for backtest research to isolate which gate contributes the edge. M5 is the sweet spot; H1 lowers trade count further. London and New York sessions provide the volume conditions that the 1.5x volume filter needs to clear.

Strategy Logic

Pipsgrowth EX12035 MultiIndicatorConfluence — Strategy Logic Analysis (from .mq5 source)

Family: MultiIndicatorConfluence Magic: 22212035 Version: 2.00

BRIEF: Ichimoku Kinko Hyo confluence EA with Tenkan/Kijun cross confirmed by Chikou span, Kumo cloud, price-vs-cloud, volume, MACD and RSI filters. Reverses on opposite signal. 12 layers: REGIME, SIGNAL, ENTRY, CONFIRM, NO-TRADE, CAPITAL CAP, RISK, SIZING, MANAGE, EXIT, SCALING, OnTester

INDICATOR STACK:

  • Standard MT5 indicators

KEY FUNCTIONS:

  • GetIndicatorValues()
  • CheckOpenPositions()
  • CheckBuySignal()
  • CheckSellSignal()
  • OpenBuy()
  • OpenSell()
  • CloseBuyPositions()
  • CloseSellPositions()
  • TryClose_EX12035()
  • TryClosePartial_EX12035()
  • TryModify_EX12035()

INTERNAL CONSTANTS (0 total):

INPUT PARAMETERS (23 total across 6 groups):

  • [=== Trade Management ===] LotSize = 0.1 // Trade lot size
  • [=== Trade Management ===] StopLoss = 100 // Stop loss in points
  • [=== Trade Management ===] TakeProfit = 200 // Take profit in points
  • [=== Trade Management ===] MagicNumber = 22212035 // Magic number for trades
  • [=== Trade Management ===] Slippage = 3 // Slippage in points
  • [=== Trade Management ===] InpTradeComment = "Psgrowth.com Expert_12035" // Trade comment
  • [=== Strategy Parameters ===] Tenkan = 9 // Tenkan-sen period
  • [=== Strategy Parameters ===] Kijun = 26 // Kijun-sen period
  • [=== Strategy Parameters ===] Senkou = 52 // Senkou Span B period
  • [=== Confirmation Filters ===] UseChikouFilter = true // Use Chikou Span filter
  • [=== Confirmation Filters ===] UseCloudFilter = true // Use Kumo (Cloud) filter
  • [=== Confirmation Filters ===] UsePriceCloudFilter = true // Use Price relative to Cloud filter
  • [=== Volume Filter ===] UseVolumeFilter = true // Use volume filter
  • [=== Volume Filter ===] MinVolumeMultiplier = 1.5 // Minimum volume multiplier vs average
  • [=== Volume Filter ===] VolumeAveragePeriod = 20 // Period for volume average
  • [=== MACD Filter ===] UseMACDFilter = true // Use MACD filter
  • [=== MACD Filter ===] MACDFastPeriod = 12 // MACD Fast EMA period
  • [=== MACD Filter ===] MACDSlowPeriod = 26 // MACD Slow EMA period
  • [=== MACD Filter ===] MACDSignalPeriod = 9 // MACD Signal period
  • [=== RSI Filter ===] UseRSIFilter = true // Use RSI filter
  • [=== RSI Filter ===] RSIPeriod = 14 // RSI period
  • [=== RSI Filter ===] RSIOverbought = 70.0 // RSI overbought level
  • [=== RSI Filter ===] RSIOversold = 30.0 // RSI oversold level
Pseudocode
// Pipsgrowth EX12035 MultiIndicatorConfluence — Execution Flow (from source analysis)
// Family: MultiIndicatorConfluence
// Ichimoku Kinko Hyo confluence EA with Tenkan/Kijun cross confirmed by Chikou span, Kumo cloud, price-vs-cloud, volume, MACD and RSI filters. Reverses on opposite signal. 12 layers: REGIME, SIGNAL, ENTRY, CONFIRM, NO-TRADE, CAPITAL CAP, RISK, SIZING, MANAGE, EXIT, SCALING, OnTester

ON_INIT:
    Create indicator handles: standard set
    Initialize state variables
    Detect broker GMT offset

ON_TICK:
    1. Refresh indicator buffers (closed-bar shift=1)
    2. Manage existing positions:
       - Break-even check
       - ATR trailing stop
       - Profit lock ratchet
       - Time-based exit
       - Opposite-signal exit
    3. If new bar:
       a. ClassifyRegime() — ADX/ATR/BB regime detection
       b. NoTradeGate() checks:
          - Market open + session filter
          - Spread limit
          - Cooldown after loss
          - Consecutive loss limit
          - Kill switch
          - Max drawdown
          - Max concurrent positions
          - Daily/weekly loss limits
       c. GenerateSignal() — strategy-specific entry logic
       d. CheckConfirm() — HTF alignment + R:R + ADX minimum
       e. Calculate position size from risk %
       f. Execute with retry logic
       g. Mark bar to prevent duplicates

ON_TESTER:
    Custom fitness = weighted(RecoveryFactor, ROI, ProfitFactor, TradeCount, Sharpe, Drawdown)

Optimization Profile

Optimized Brokers:
ExnessIC Markets
Optimized Symbols:
XAUUSD
Optimized Timeframes:
M5H1

How to Install This EA on MT5

  1. 1Download the .mq5 file using the button above
  2. 2Open MetaTrader 5 on your computer
  3. 3Click File → Open Data Folder in the top menu
  4. 4Navigate to MQL5 → Experts and paste the .mq5 file there
  5. 5In MT5, right-click Expert Advisors in the Navigator panel → Refresh
  6. 6Drag the EA onto a chart matching the recommended timeframe
  7. 7Configure parameters according to the table on this page
  8. 8Enable Allow Algo Trading and click OK

EA Parameters

ParameterDefaultDescription
LotSize0.1Trade lot size
StopLoss100Stop loss in points
TakeProfit200Take profit in points
MagicNumber22212035Magic number for trades
Slippage3Slippage in points
InpTradeComment"Psgrowth.com Expert_12035"Trade comment
Tenkan9Tenkan-sen period
Kijun26Kijun-sen period
Senkou52Senkou Span B period
UseChikouFiltertrueUse Chikou Span filter
UseCloudFiltertrueUse Kumo (Cloud) filter
UsePriceCloudFiltertrueUse Price relative to Cloud filter
UseVolumeFiltertrueUse volume filter
MinVolumeMultiplier1.5Minimum volume multiplier vs average
VolumeAveragePeriod20Period for volume average
UseMACDFiltertrueUse MACD filter
MACDFastPeriod12MACD Fast EMA period
MACDSlowPeriod26MACD Slow EMA period
MACDSignalPeriod9MACD Signal period
UseRSIFiltertrueUse RSI filter
RSIPeriod14RSI period
RSIOverbought70.0RSI overbought level
RSIOversold30.0RSI oversold level
Source Code (.mq5)Open Source
Pipsgrowth_com_EX12035.mq5
#property copyright "Pipsgrowth.com"
#property link      "https://pipsgrowth.com"
#property version   "2.00"
#property strict
#property description "Pipsgrowth.com EX12035 EA401 — Ichimoku confluence with multi-filter confirmation, full 12-layer stack."
#include <Trade\Trade.mqh>

//--- Input parameters
input group "=== Trade Management ==="
input double LotSize = 0.1;           // Trade lot size
input int StopLoss = 100;             // Stop loss in points
input int TakeProfit = 200;           // Take profit in points
input int MagicNumber = 22212035;     // Magic number for trades
input int Slippage = 3;               // Slippage in points
input string InpTradeComment = "Psgrowth.com Expert_12035"; // Trade comment

//--- Ichimoku parameters
input group "=== Strategy Parameters ==="
input int Tenkan = 9;                 // Tenkan-sen period
input int Kijun = 26;                 // Kijun-sen period
input int Senkou = 52;                // Senkou Span B period

//--- Trading conditions
input group "=== Confirmation Filters ==="
input bool UseChikouFilter = true;    // Use Chikou Span filter
input bool UseCloudFilter = true;     // Use Kumo (Cloud) filter
input bool UsePriceCloudFilter = true;// Use Price relative to Cloud filter

//--- Additional filters
input group "=== Volume Filter ==="
input bool UseVolumeFilter = true;    // Use volume filter
input double MinVolumeMultiplier = 1.5; // Minimum volume multiplier vs average
input int VolumeAveragePeriod = 20;   // Period for volume average

input group "=== MACD Filter ==="
input bool UseMACDFilter = true;      // Use MACD filter
input int MACDFastPeriod = 12;        // MACD Fast EMA period
input int MACDSlowPeriod = 26;        // MACD Slow EMA period
input int MACDSignalPeriod = 9;       // MACD Signal period

input group "=== RSI Filter ==="
input bool UseRSIFilter = true;       // Use RSI filter
input int RSIPeriod = 14;             // RSI period
input double RSIOverbought = 70.0;    // RSI overbought level
input double RSIOversold = 30.0;      // RSI oversold level

//--- Global variables
int ichimokuHandle;                   // Handle for Ichimoku indicator
double tenkanBuffer[];                // Tenkan-sen buffer
double kijunBuffer[];                 // Kijun-sen buffer
double spanABuffer[];                 // Senkou Span A buffer
double spanBBuffer[];                 // Senkou Span B buffer
double chikouBuffer[];                // Chikou Span buffer

//--- Additional indicator handles and buffers
int macdHandle;                       // Handle for MACD indicator
double macdMainBuffer[];              // MACD main line buffer
double macdSignalBuffer[];            // MACD signal line buffer

int rsiHandle;                        // Handle for RSI indicator

Full source code available on download

Educational purposes only. Do NOT use with real money. Test on demo accounts only.

Tags:ex12035multiindicatorconfluencepipsgrowthfreemt5xauusd

Clear Warning: Educational Purposes Only

Clear Warning: This Expert Advisor is for educational and testing purposes only. Do NOT use it with real money. Test only on demo accounts. Trading with real money involves substantial risk of capital loss. This does not constitute investment advice.

Recommended Brokers for This EA

These EAs run on MT5 — use a regulated broker with fast execution and tight spreads

Community

Sign in to contributeSign In

Educational purposes only. Do NOT use with real money. Test on demo accounts only.

File NamePipsgrowth_com_EX12035.mq5
File Size21.6 KB
Versionv2.00
PlatformMetaTrader 5
File Type.mq5 Source
StrategyOther
Risk LevelMedium Risk
Timeframes
M5H1
Currency Pairs
XAUUSD
Min. Deposit$100