P
PipsGrowth
ScalpingOpen Source – Free

Pipsgrowth EX14013 Scalper

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

Pipsgrowth.com EX14013 MillionaireScalper — Stochastic/KAMA/ATR/ADX scalper with candlestick patterns and divergence, full 12-layer stack.

Overview

Pipsgrowth EX14013 MillionaireScalper is a five-confirmation, multi-handle scalping engine that opens positions only when Stochastic, KAMA, a candlestick pattern, optional divergence, and a market-regime classifier all agree. The EA is built around a strict additive logic: the first three conditions form the core signal, divergence tightens the entry, and the regime classifier blocks trades it considers unsafe. With 50 inputs across ten groups, this is one of the most configurable EAs in the EX14 family, but the live code is much narrower than the parameter dialog suggests — most of the SL/TP, trailing, and breakeven logic runs on ATR, not on the visible pip inputs.

The OnInit sequence builds five native indicator handles: iStochastic(5,3,3) on MODE_SMA / STO_LOWHIGH, iAMA configured as a KAMA with period 10, fast MA 2, slow MA 30 on PRICE_CLOSE, iATR(14), iADX(14), and a single iMA(100, MODE_EMA, PRICE_CLOSE) used purely as a trend filter. Each of these has its own timeframe input (InpStochTimeframe, InpKAMATimeframe, InpATRTimeframe, InpADXTimeframe, InpMATimeframe), all default to 0 — and the MapTimeframeInt() helper returns PERIOD_H1 whenever the input is 0. That default fallback means every indicator runs on the H1 timeframe out of the box, regardless of the chart timeframe. M5 chart, H1 indicator stack: a deliberate higher-timeframe-filter design.

The signal chain on every tick is layered. First, the Stochastic must cross up below the buy level of 20 (main line crosses above signal line, both current and previous bars sit below 20) for a BUY, or cross down above the sell level of 80 for a SELL. If that fires, the EA checks whether Ask > KAMA (for buys) or Bid < KAMA (for sells) — KAMA is the adaptive trend baseline. Third, a candlestick pattern must confirm: any of the enabled Engulfing, Hammer, or Doji patterns on bar 0 (the Doji variants require the previous bar to be the opposite color). If all three pattern toggles are off, the EA skips the pattern gate. Fourth, the optional Stochastic divergence function scans the last 20 bars for a price-low / stoch-higher-low (or mirror) setup; if divergence detection is enabled, divergence must agree. Fifth, the regime classifier must place the market in TREND_UP or RANGE_CALM for buys, TREND_DOWN or RANGE_CALM for sells. Any one of those gates missing → no entry.

The GetMarketRegime() function reads ADX, +DI, -DI, and the 100-EMA. When ADX(14) exceeds the 25.0 trend threshold, the EA looks at both +DI/-DI and price-vs-MA slope. If +DI dominates with price above a rising MA, it returns TREND_UP; if -DI dominates with price below a falling MA, TREND_DOWN. When ADX is at or below 25, the EA classifies as ranging, and uses ATR to split that into RANGE_CALM (ATR < 20 points on a 5-digit broker = under 2 pips) or RANGE_VOLATILE. RANGE_VOLATILE is the only regime where CalculateLotSize cuts effective risk by 25% — the rest use full InpRiskPercent. The TREND_UP / TREND_DOWN / RANGE_CALM buckets are the tradeable zones; RANGE_VOLATILE and UNKNOWN are blocked at the entry gate.

Position sizing runs through CalculateLotSize(), which uses ATR × 1.5 as the assumed stop distance and divides balance × InpRiskPercent (default 1%) by the per-lot value. The lot is then floored to the symbol's _lotStep and clipped to _minLot / _maxLot. When InpUseRiskPercent is false, the EA falls back to the fixed InpFixedLots = 0.01. Each trade opens with a hardcoded deviation of 10 points and ORDER_FILLING_FOK.

The TP / SL sent to the broker at fill come from currentATR × InpATRTakeProfitMultiplier (default 2.0) and currentATR × InpATRStopLossMultiplier (default 1.5). The InpTakeProfitPips (100) and InpStopLossPips (50) inputs are visible in the dialog but are not what gets sent to the broker — the live SL/TP are always ATR-relative. The 2.0/1.5 defaults give roughly a 1.33:1 reward-to-risk ratio on every fill.

ManagePositions() handles the trade lifecycle. Breakeven fires once: if the SL hasn't been set yet (currentSL == 0) and the trade is at least InpBreakevenPips = 20 points in profit, the EA sets SL to entry + InpBreakevenOffsetPips = 5 points. After that one application, the SL is non-zero and the breakeven block never fires again. Trailing runs on every subsequent tick using currentATR × 1.5 as the distance, and only ratchets tighter — the code only modifies when the new level beats the current SL. The same InpTrailingStopPips input that gates the trailing block (50 points) acts as a kill switch, not a distance: trailing only enables when this input is greater than zero.

The session filter (InpEnableTradingSessions, default true) wraps a custom 8-hour window: InpStartHour = 9 to InpEndHour = 17, server time, with per-day toggles for Monday through Friday. Every tick outside the window calls CloseAllTradesIfOutsideSession(), which iterates positions and sends TRADE_ACTION_CLOSE_BY (a hedge-mode close that becomes a flat close on a netting account). This is the only time-based exit the EA has — there is no time-based bar exit, no session-specific TP, no Friday close-all.

The single largest safety control is the 10% drawdown kill switch. InpMaxDrawdown = 10.0 compares (initialBalance - currentEquity) / initialBalance against 10% on every tick. If breached, CheckMaxDrawdown() closes all open positions on the magic and calls ExpertRemove(), which permanently stops the EA on that chart. There is no reset, no soft-cap — the EA does not come back automatically. This is the only drawdown control the EA has; there is no daily loss limit, no per-trade trailing cap, no equity-curve filter.

Other capacity controls: InpMaxOpenTrades = 5 caps total open positions, and HasOpenPosition() blocks opening a second BUY or a second SELL while one is already on the same magic. The combination of single-direction + 5-max creates a soft pyramid: the EA can stack up to 5 buys or 5 sells, but cannot hedge. New-bar filtering, lot-step rounding, and max-lot clamping are all wired.

The audit reveals three defined-but-unused retry helpers at the bottom of the file — TryClose_EX14013, TryClosePartial_EX14013, and TryModify_EX14013 — each looping three times on REQUOTE / TIMEOUT / PRICE_OFF / PRICE_CHANGED before giving up. No live call site invokes them; OpenTrade, ModifyPosition, CloseAllTradesIfOutsideSession, and CheckMaxDrawdown all call OrderSend directly. The header advertises twelve layers (REGIME / SIGNAL / ENTRY / CONFIRM / NO-TRADE / CAPITAL CAP / RISK / SIZING / MANAGE / EXIT / SCALING / OnTester) but the actually-wired layers are eleven — SCALING is missing (no martingale, no scale-in, no grid) and OnTester is not implemented. Everything else is in the live code path.

Strategy Deep Dive

On every tick the EA refreshes the five native indicator buffers (Stochastic, KAMA, ATR, ADX, MA-100) on their H1 timeframe, then runs a five-stage gate. Stage 1: Stochastic %K must have just crossed %D on the right side of the 20 / 80 line. Stage 2: the live price must be on the right side of KAMA. Stage 3: a candlestick pattern (Engulfing / Hammer / Doji) must confirm on bar 0. Stage 4: if divergence is enabled, a 20-bar Stochastic divergence must agree. Stage 5: GetMarketRegime() must classify the market as TREND_UP or RANGE_CALM for buys, TREND_DOWN or RANGE_CALM for sells; the classifier itself reads ADX(14) against 25.0, splits trending by +DI/-DI dominance and MA(100) slope, and splits ranging by ATR(14) at a 20-point threshold. A pass on all five stages calls CalculateLotSize() (1% of balance divided by ATR × 1.5, floored to lot step, regime-reduced by 25% only in RANGE_VOLATILE) and OpenTrade() with ORDER_FILLING_FOK, 10-point deviation, ATR-based SL/TP, and a hard cap of 5 open positions via InpMaxOpenTrades + HasOpenPosition(). The session window 9–17 forces a close-all outside hours, and the 10% drawdown check closes all and calls ExpertRemove() permanently if breached.

Entry Signal

BUY entries require a Stochastic %K/%D cross up below the 20 buy level with Ask above KAMA, a confirmed bullish candlestick pattern (Engulfing / Hammer / Doji after a bearish bar) on bar 0, and a market regime of TREND_UP or RANGE_CALM. SELL entries mirror the logic on a Stochastic cross down above the 80 sell level with Bid below KAMA and a bearish pattern; the regime must be TREND_DOWN or RANGE_CALM. Optional Stochastic divergence (20-bar lookback) tightens the entry if enabled, and the EA will not stack a second position in the same direction while one is already open on magic 22214013.

Exit Signal

Exits happen via three independent paths: the broker-side TP and SL set at fill (ATR × 2.0 and ATR × 1.5 by default), the trailing stop in ManagePositions that ratchets to currentATR × 1.5 below the ask (or above the bid for sells) on every tick once the position is in profit, and the breakeven snap that fires once per position when profit exceeds 20 points and locks SL to entry + 5 points. Additionally, CloseAllTradesIfOutsideSession() force-closes every open position whenever the server clock is outside the 9–17 window or on a non-trading weekday, and CheckMaxDrawdown() force-closes all positions and calls ExpertRemove() permanently if equity drawdown from initial balance hits the 10% threshold.

Stop Loss

Per-trade stop loss is set at order fill to currentATR × InpATRStopLossMultiplier (1.5 by default), then ManagePositions() can ratchet the SL tighter to breakeven after 20 points of profit (offset +5) and continue trailing at currentATR × 1.5 below the ask / above the bid on every subsequent tick. A 10% equity drawdown from the initial balance triggers a hard close-all and ExpertRemove() that permanently stops the EA; the visible InpStopLossPips = 50 input is in the dialog but is not the value used at fill.

Take Profit

Per-trade take profit is set at order fill to currentATR × InpATRTakeProfitMultiplier (2.0 by default), giving roughly a 1.33:1 reward-to-risk ratio against the 1.5×ATR stop. There is no basket TP, no scaling-out, and no partial close on this EA — every exit is either the broker-side TP, the SL, the trailing stop ratchet, the breakeven snap, the session-end force-close, or the 10% drawdown kill switch. The InpTakeProfitPips = 100 input visible in the dialog is not the value used at fill.

Best For

Best deployed on XAUUSD M5 with a $100 minimum account (the EA itself claims a 1% per-trade risk, so $100 absorbs 3-4 consecutive ATR×1.5 stops on gold before the 10% drawdown kill switch fires). The default session window 9–17 server time is the only tradeable band — flip InpEnableTradingSessions to false only if you understand you are also disabling the 9-17 force-close, which leaves positions running into the Asian session low-liquidity window. Brokers that offer ECN-style execution with sub-30ms latency and ORDER_FILLING_FOK support are mandatory for the H1 indicator stack + M5 chart combination; the 10-point deviation inside OpenTrade gives no headroom on slow feeds. Avoid the EA on netting accounts where TRADE_ACTION_CLOSE_BY in CloseAllTradesIfOutsideSession and CheckMaxDrawdown will behave differently than on a hedge account.

Strategy Logic

Pipsgrowth EX14013 Scalper — Strategy Logic Analysis (from .mq5 source)

Family: Scalper Magic: 22214013 Version: 2.00

BRIEF: Advanced high-frequency scalping EA using Stochastic, KAMA, ATR, and ADX indicators with candlestick patterns and divergence detection. Features dynamic risk management, profit protection, and session filtering. 12 layers: REGIME, SIGNAL, ENTRY, CONFIRM, NO-TRADE, CAPITAL CAP, RISK, SIZING, MANAGE, EXIT, SCALING, OnTester

INDICATOR STACK:

  • Standard MT5 indicators

KEY FUNCTIONS:

  • HasOpenPosition()
  • IsBullishStochasticDivergence()
  • IsBearishStochasticDivergence()
  • IsBullishEngulfing()
  • IsBearishEngulfing()
  • IsHammer()
  • IsShootingStar()
  • IsDoji()
  • IsBullishDoji()
  • IsBearishDoji()
  • CalculateLotSize()
  • OpenTrade()
  • ...and 8 more

INTERNAL CONSTANTS (0 total):

INPUT PARAMETERS (50 total across 11 groups):

  • [=== General Settings ===] InpMagicNumber = 22214013 // Magic Number
  • [=== General Settings ===] InpEAName = "MillionaireScalper" // EA Name for comments
  • [=== General Settings ===] InpTradeComment = "Psgrowth.com Expert_14013" // Order comment
  • [=== Risk Management ===] InpFixedLots = 0.01 // Fixed Lots (if InpUseRiskPercent is false)
  • [=== Risk Management ===] InpUseRiskPercent = true // Use Risk Percentage for Lot Sizing
  • [=== Risk Management ===] InpRiskPercent = 1.0 // Risk Percentage per trade (e.g., 1.0 for 1%)
  • [=== Risk Management ===] InpMaxDrawdown = 10.0 // Maximum allowed drawdown in percentage
  • [=== Trade Management ===] InpTakeProfitPips = 100 // Take Profit in points (10 pips = 100 points for 5-digit brokers)
  • [=== Trade Management ===] InpStopLossPips = 50 // Stop Loss in points (5 pips = 50 points for 5-digit brokers)
  • [=== Trade Management ===] InpTrailingStopPips = 50 // Trailing Stop in points
  • [=== Trade Management ===] InpBreakevenPips = 20 // Breakeven in points
  • [=== Trade Management ===] InpBreakevenOffsetPips = 5 // Breakeven offset in points
  • [=== ATR Settings ===] InpATRTimeframe = 0 // Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // ATR Timeframe
  • [=== ATR Settings ===] InpATRPeriod = 14 // ATR Period
  • [=== ATR Settings ===] InpATRStopLossMultiplier = 1.5 // Multiplier for ATR to set Stop Loss
  • [=== ATR Settings ===] InpATRTakeProfitMultiplier = 2.0 // Multiplier for ATR to set Take Profit
  • [=== Stochastic Settings ===] InpStochTimeframe = 0 // Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // Stochastic Timeframe
  • [=== Stochastic Settings ===] InpStochKPeriod = 5 // K-period
  • [=== Stochastic Settings ===] InpStochDPeriod = 3 // D-period
  • [=== Stochastic Settings ===] InpStochSlowing = 3 // Slowing
  • [=== Stochastic Settings ===] InpStochMethod = MODE_SMA // Moving Average Method
  • [=== Stochastic Settings ===] InpStochPriceField = STO_LOWHIGH // Price Field
  • [=== Stochastic Settings ===] InpStochBuyLevel = 20 // Buy Level
  • [=== Stochastic Settings ===] InpStochSellLevel = 80 // Sell Level
  • [=== KAMA Settings ===] InpKAMATimeframe = 0 // Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // KAMA Timeframe
  • [=== KAMA Settings ===] InpKAMAPeriod = 10 // KAMA Period (Efficiency Ratio Period)
  • [=== KAMA Settings ===] InpKAMAFastMA = 2 // KAMA Fast MA Period
  • [=== KAMA Settings ===] InpKAMASlowMA = 30 // KAMA Slow MA Period
  • [=== KAMA Settings ===] InpKAMAPrice = 1 // Applied price (1=close,2=open,3=high,4=low,5=median,6=typical,7=weighted) // Applied Price
  • [=== Market Regime Settings ===] InpADXTimeframe = 0 // Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // ADX Timeframe
  • [=== Market Regime Settings ===] InpADXPeriod = 14 // ADX Period
  • [=== Market Regime Settings ===] InpADXTrendThreshold = 25.0 // ADX value above which market is considered trending
  • [=== Market Regime Settings ===] InpMATimeframe = 0 // Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // Moving Average Timeframe
  • [=== Market Regime Settings ===] InpMAPeriod = 100 // Moving Average Period for trend detection
  • [=== Market Regime Settings ===] InpMAMethod = MODE_EMA // Moving Average Method
  • [=== Market Regime Settings ===] InpMAPrice = 1 // Applied price (1=close,2=open,3=high,4=low,5=median,6=typical,7=weighted) // Applied Price
  • [=== Session Management ===] InpEnableTradingSessions = true // Enable Trading Sessions
  • [=== Session Management ===] InpStartHour = 9 // Start Hour (e.g., 9 for 9:00 AM)
  • [=== Session Management ===] InpEndHour = 17 // End Hour (e.g., 17 for 5:00 PM)
  • [=== Session Management ===] InpTradeMonday = true // Trade on Monday
  • [=== Session Management ===] InpTradeTuesday = true // Trade on Tuesday
  • [=== Session Management ===] InpTradeWednesday = true // Trade on Wednesday
  • [=== Session Management ===] InpTradeThursday = true // Trade on Thursday
  • [=== Session Management ===] InpTradeFriday = true // Trade on Friday
  • [=== Account Protection ===] InpMaxOpenTrades = 5 // Maximum number of open trades
  • [=== Candlestick Pattern Settings ===] InpEnableEngulfing = true // Enable Engulfing Pattern detection
  • [=== Candlestick Pattern Settings ===] InpEnableHammerShootingStar = true // Enable Hammer/Shooting Star detection
  • [=== Candlestick Pattern Settings ===] InpEnableDoji = true // Enable Doji detection
  • [=== Divergence Settings ===] InpEnableStochDivergence = true // Enable Stochastic Divergence detection
  • [=== Divergence Settings ===] InpDivergenceLookbackBars = 20 // Number of bars to look back for divergence
Pseudocode
// Pipsgrowth EX14013 Scalper — Execution Flow (from source analysis)
// Family: Scalper
// Advanced high-frequency scalping EA using Stochastic, KAMA, ATR, and ADX indicators with candlestick patterns and divergence detection. Features dynamic risk management, profit protection, and session filtering. 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 from the Navigator onto any chart (M1 or M5 recommended)
  7. 7In the EA dialog, enable Allow Algo Trading and set your lot size
  8. 8Click OK — the EA will begin trading automatically

EA Parameters

ParameterDefaultDescription
InpMagicNumber22214013Magic Number
InpEAName"MillionaireScalper"EA Name for comments
InpTradeComment"Psgrowth.com Expert_14013"Order comment
InpFixedLots0.01Fixed Lots (if InpUseRiskPercent is false)
InpUseRiskPercenttrueUse Risk Percentage for Lot Sizing
InpRiskPercent1.0Risk Percentage per trade (e.g., 1.0 for 1%)
InpMaxDrawdown10.0Maximum allowed drawdown in percentage
InpTakeProfitPips100Take Profit in points (10 pips = 100 points for 5-digit brokers)
InpStopLossPips50Stop Loss in points (5 pips = 50 points for 5-digit brokers)
InpTrailingStopPips50Trailing Stop in points
InpBreakevenPips20Breakeven in points
InpBreakevenOffsetPips5Breakeven offset in points
InpATRTimeframe0Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // ATR Timeframe
InpATRPeriod14ATR Period
InpATRStopLossMultiplier1.5Multiplier for ATR to set Stop Loss
InpATRTakeProfitMultiplier2.0Multiplier for ATR to set Take Profit
InpStochTimeframe0Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // Stochastic Timeframe
InpStochKPeriod5K-period
InpStochDPeriod3D-period
InpStochSlowing3Slowing
InpStochMethodMODE_SMAMoving Average Method
InpStochPriceFieldSTO_LOWHIGHPrice Field
InpStochBuyLevel20Buy Level
InpStochSellLevel80Sell Level
InpKAMATimeframe0Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // KAMA Timeframe
InpKAMAPeriod10KAMA Period (Efficiency Ratio Period)
InpKAMAFastMA2KAMA Fast MA Period
InpKAMASlowMA30KAMA Slow MA Period
InpKAMAPrice1Applied price (1=close,2=open,3=high,4=low,5=median,6=typical,7=weighted) // Applied Price
InpADXTimeframe0Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // ADX Timeframe
InpADXPeriod14ADX Period
InpADXTrendThreshold25.0ADX value above which market is considered trending
InpMATimeframe0Timeframe (1=M1,2=M5,3=M15,4=M30,5=H1,6=H4,7=D1) // Moving Average Timeframe
InpMAPeriod100Moving Average Period for trend detection
InpMAMethodMODE_EMAMoving Average Method
InpMAPrice1Applied price (1=close,2=open,3=high,4=low,5=median,6=typical,7=weighted) // Applied Price
InpEnableTradingSessionstrueEnable Trading Sessions
InpStartHour9Start Hour (e.g., 9 for 9:00 AM)
InpEndHour17End Hour (e.g., 17 for 5:00 PM)
InpTradeMondaytrueTrade on Monday
InpTradeTuesdaytrueTrade on Tuesday
InpTradeWednesdaytrueTrade on Wednesday
InpTradeThursdaytrueTrade on Thursday
InpTradeFridaytrueTrade on Friday
InpMaxOpenTrades5Maximum number of open trades
InpEnableEngulfingtrueEnable Engulfing Pattern detection
InpEnableHammerShootingStartrueEnable Hammer/Shooting Star detection
InpEnableDojitrueEnable Doji detection
InpEnableStochDivergencetrueEnable Stochastic Divergence detection
InpDivergenceLookbackBars20Number of bars to look back for divergence
Source Code (.mq5)Open Source
Pipsgrowth_com_EX14013.mq5
#property copyright "Pipsgrowth.com"
#property link      "https://pipsgrowth.com"
#property version   "2.00"
#property strict
#property description "Pipsgrowth.com EX14013 MillionaireScalper — Stochastic/KAMA/ATR/ADX scalper with candlestick patterns and divergence, full 12-layer stack."

#include <Trade/Trade.mqh>
#include <Indicators/Indicators.mqh>

//--- Input Parameters ---
//=== General Settings ===
ENUM_TIMEFRAMES MapTimeframeInt(int tf)
{
   switch(tf)
   {
      case 1: return PERIOD_M1;
      case 2: return PERIOD_M5;
      case 3: return PERIOD_M15;
      case 4: return PERIOD_M30;
      case 5: return PERIOD_H1;
      case 6: return PERIOD_H4;
      case 7: return PERIOD_D1;
      default: return PERIOD_H1;
   }
}

ENUM_APPLIED_PRICE MapAppliedPriceInt(int ap)
{
   switch(ap)
   {
      case 1: return PRICE_CLOSE;
      case 2: return PRICE_OPEN;
      case 3: return PRICE_HIGH;
      case 4: return PRICE_LOW;
      case 5: return PRICE_MEDIAN;
      case 6: return PRICE_TYPICAL;
      case 7: return PRICE_WEIGHTED;
      default: return PRICE_CLOSE;
   }
}
ENUM_TIMEFRAMES g_InpATRTimeframe = PERIOD_H1;
ENUM_TIMEFRAMES g_InpStochTimeframe = PERIOD_H1;
ENUM_TIMEFRAMES g_InpKAMATimeframe = PERIOD_H1;
ENUM_TIMEFRAMES g_InpADXTimeframe = PERIOD_H1;
ENUM_TIMEFRAMES g_InpMATimeframe = PERIOD_H1;
ENUM_APPLIED_PRICE g_InpKAMAPrice = PRICE_CLOSE;
ENUM_APPLIED_PRICE g_InpMAPrice = PRICE_CLOSE;
input group "=== General Settings ==="
input long   InpMagicNumber = 22214013;      // Magic Number
input string InpEAName      = "MillionaireScalper"; // EA Name for comments
input string InpTradeComment = "Psgrowth.com Expert_14013"; // Order comment

//=== Risk Management ===
ENUM_TIMEFRAMES MapTimeframeInt(int tf)
{
   switch(tf)
   {
      case 1: return PERIOD_M1;
      case 2: return PERIOD_M5;
      case 3: return PERIOD_M15;

Full source code available on download

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

Tags:ex14013scalperpipsgrowthfreemt5xauusd

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_EX14013.mq5
File Size52.5 KB
Versionv2.00
PlatformMetaTrader 5
File Type.mq5 Source
StrategyScalping
Risk LevelHigh Risk
Timeframes
M5H1
Currency Pairs
XAUUSD
Min. Deposit$100