Grid Coppock Curve EA
- Experts
-
AL MOOSAWI ABDULLAH JAFFER BAQER
To trade successfully we need to go through the proven path that others had gone and reached!
Here are 17 quotes from such successful investors:
1- Limit your size in any position so that fear does not become the prevailing instinct guiding your judgment.
Joe Vidich - Versão: 3.18
- Ativações: 5
Test it before you trust it: open Grid Coppock Curve EA in the MetaTrader 5 Strategy Tester, switch on visual mode, and watch which turns of the curve it takes and which ones it lets go.
BUY THE EXHAUSTION, NOT THE PANIC.
Edwin Coppock built his curve for one job: to notice when a fall has run out of breath. It adds a long and a short rate of change and smooths them with a weighted average, so the line sinks while selling continues and then bends upward once the decline loses speed, usually while it is still below zero. Grid Coppock Curve EA takes that bend, the hook, as the moment to begin. It waits for the hook on a finished bar, checks that the market is moving enough to matter and that the bigger trend agrees, and only then lets the grid engine open the first level. From there the engine does the patient part: it banks small group closures and trims heavy old orders one slice at a time.
Five things to know first
• Entry: the Coppock Curve hooks up below zero after falling for 2 bars (BUY), or hooks down above zero after rising (SELL), read on a closed bar. Accepted signals do not repaint.
• The curve is calculated inside the EA from closes: WMA 10 of ROC 14 plus ROC 11. No indicator file, no DLL, no web request.
• A Range Guard skips quiet boxes and an EMA 200 filter keeps entries on the side of the main trend. A zero line cross mode is included as an alternative.
• New in this product: the Depth Guard, which can refuse hooks that happen too close to zero. It ships switched off, and the measured reason is printed below.
• No stop loss and no forced close-all. Limits stop new levels; the open book stays under management.
----------
Start here (5 minutes)
1. Attach it to EURUSD H1 and leave every input at its default (0.01 first lot, additive ladder, ATR spacing).
2. Set RunMode to Scan only for the first session. The panel shows each plan; no order is sent.
3. When the plans make sense to you, press ARMED on the panel.
4. Repeat the tester runs below with your own broker's data before any real money; spread, swap and commission all move the result.
5. More than one chart? Give each copy its own EAMagicNumber and HedgeMagicNumber.
----------
Reproduce our numbers
Strategy Tester, default inputs, 1 minute OHLC, leverage 1:100, 2025.01.01 to 2026.09.30, one broker's demo data. Same settings, same period, and you should land close to these:
• EURUSD H1, $10,000: net +704.99, maximal equity drawdown 248.61 (2.39%), 334 trades. No stop-out, no margin refusal.
• EURUSD H1, $1,000,000: net +704.99, maximal equity drawdown 248.61 (0.02%), 334 trades. No stop-out, no margin refusal.
• XAUUSD D1, $10,000: net +19.37, maximal equity drawdown 2.20 (0.02%), 6 trades. No stop-out, no margin refusal.
• XAUUSD D1, $1,000,000: net +19.37, maximal equity drawdown 2.20 (0.00%), 6 trades. No stop-out, no margin refusal.
Read these as one past stretch, not a forecast. The drawdown in money is the same at both deposits because lots do not grow with the balance, so 248.61 is about 2.4% of $10,000 and a bigger share of a smaller account; deposits below $10,000 were not tested. Six gold trades in 21 months is far too few to judge gold. Defaults were set once by judgement on this same period, which flatters them. Netting accounts were not verified.
----------
The Depth Guard and why it ships off
The idea: a hook that turns just under zero is a shrug, not exhaustion, so a BUY could be required to turn from at least a set depth below zero (InpCPKDepthMin). We tested it on EURUSD H1, $10,000, everything else at default. With a depth of 0.15: net +668.48, drawdown 248.61 (2.39%), 311 trades. Off: net +704.99, drawdown 248.61 (2.39%), 334 trades. On XAUUSD D1 both runs were identical (6 trades, +19.37), because daily gold hooks are deep anyway. The guard removed 23 trades and 36.51 of profit without lowering the drawdown at all, so it did not make the EA safer, and it stays at 0. It is there for you if you want fewer, deeper entries: try 0.15 on EURUSD and compare on your own data. Units are Coppock percent, so a sensible value on gold or indices is larger.
----------
Why the Coppock Curve
Most oscillators measure where price sits in a range. Coppock measures how fast price is changing, over two horizons at once, and smooths the result with the newest bars weighted most. That makes the turn of the curve, not its level, the useful event: it bends when a move decelerates. A grid that should start once and then let its engine work suits that well. The cost is honest too: the curve is built from past closes, the hook comes after price has already turned a little, and in a flat market the curve can hook back and forth near zero. The Range Guard, the trend filter and the 30 bar signal gap are there for exactly that.
----------
One cycle, step by step
1. Read. Each new bar rebuilds both rates of change and the weighted average from finished bars.
2. Hook. In the default hook mode the curve must have fallen for InpCPKHookBars bars and then rise, while still below zero, for a BUY; the mirror above zero for a SELL. In zero mode, a cross of the zero line is the event.
3. Depth Guard, optional. The turn must come from at least InpCPKDepthMin past zero.
4. Range Guard. The last 20 bars must span at least 5 ATR, so tight boxes are skipped.
5. Trend filter. By default the close must be on the matching side of the EMA 200. It can also fade that side, or be switched off.
6. Timing. Accepted signals are kept apart by a gap of bars, and a signal may wait a few bars if the level cannot be placed at once.
7. Ladder. Levels follow ATR or fixed points, with a floor, a ceiling and an optional freeze. BUY and SELL grids can run together or alone.
8. Banking. Groups of oldest and newest orders close when their joint result, after swap and commission, clears the target. If the oldest order is too heavy, a slice of it is closed instead.
9. Safety checks. A closure that would reopen a level at once is blocked, each leg is confirmed in deal history, failed legs are retried, and a plan is dropped if the book changed before sending.
10. Hedge cycle, optional. Off by default and not exercised in our tests. When on, it holds a balanced pair on a chosen symbol and retires it in equal slices, paid by a small surcharge on closures the grid already makes.
----------
The panel
The panel sits on the left, so the right side and the price scale stay clear. It lists symbol, magic number, a status pill, grid mode, lot step, spacing, banked result, the book, each side's closing plan and the order table. The CPK PULSE row shows the ROC and WMA lengths, the curve value on the last closed bar, whether it is RISING or FALLING, and the bars since the last hook. The DEPTH GUARD row shows the favoured side, the mode, the depth of the turn with OPEN, HOLD or off, the Range Guard width in ATR with its state, and the EMA side. On the live chart every hook of the last 150 bars is marked: a small arrow when accepted, a grey dot when a guard refused it. Buttons switch Armed / Scan only, Pause / Resume, chart marks and slicing. The Hedge Vault card docks under the main panel; with the hedge off it stayed hidden in our screenshots, so the live dock was not checked. Nothing is drawn in a non-visual backtest.
----------
Limits you control
No setting closes the book for you; limits only stop new levels.
Each order passes a free margin check with a safety buffer before it is sent.
Caps on levels per grid, orders per side and lot per order keep the ladder finite. MinMarginLevelPercent and MaxAccountRiskPercent start at off; set them for your own account.
An optional margin-level timeframe safety moves the signal and spacing to a higher timeframe as margin falls. It is off by default and was not exercised in our tests.
Copies are kept apart by symbol and magic number.
Scan only shows every decision without sending a single order.
----------
Is it for you?
Yes, if you would rather start after a move has tired than chase it, are happy with many small closures, and will size lots to your balance. No, if you need a stop loss on every order, expect a fixed monthly return, or want large lots running unattended on a small deposit.
----------
Common questions
Does it repaint? Accepted signals, chart marks and both panel rows use finished bars only.
Is it the classic Coppock? Yes, the standard 14 / 11 / 10 recipe, applied to the chart timeframe instead of monthly bars. Values match any platform that uses closes and a plain WMA.
Which markets were tested? EURUSD H1 and XAUUSD D1. Everything else is for you to test.
What should I change first? InpCPKHookBars (1 gives more entries, 3 fewer), then InpCPKRangeMinATR. One change at a time, and look at drawdown next to net result.
Why so few gold trades? On a daily chart the hook below zero with the EMA 200 on the same side is rare, and the 30 bar gap thins it further.
Hook or zero mode? Hook starts earlier, near the bottom of the swing; zero mode waits for confirmation and starts later. Test both on your symbol.
Netting accounts? A separate margin cap exists for them, but netting behaviour is unverified.
----------
All inputs
Grid levels
TradeMode - two grids, BUY and SELL, by default, or one direction only.
GridSpacePoints - level distance in fixed spacing mode (25).
GridSpaceMultiplier - above 1.0 widens deeper levels (1.0 = even).
MaxGridLevels - most levels in one grid (1000).
UpDirectionIsBuy - which side an up move arms.
EAMagicNumber - number on grid orders (9768840).
GridOrderComment - text on grid orders (GCPK).
OneOrderPerBar - at most one new level per bar.
Lots
InitialLotSize - volume of the first level (0.01).
LotSizingMode - additive by default, multiply as the alternative.
LotMultiplier - factor per level in multiply mode (1.25).
LotAddStep - step per level in additive mode (0.01; 0 uses the starting lot).
MaxOrderVolume - largest single order (1.0).
UseAutoLot - links the starting lot to balance (off).
AutoLotBaseBalance - balance that matches the starting lot (1000).
AutoLotAllowDecrease - lets auto lot go below the starting lot (off).
ATR spacing
GridSpacingMode - ATR by default, fixed points as the alternative.
ATRTimeframe - ATR timeframe (current chart).
ATRPeriod - ATR length (14).
ATRSpacingFactor - spacing as a multiple of ATR (1.0).
ATRBarShift - ATR bar; 1 is the last finished bar.
ATRMinSpacingPts - lowest spacing in points (50; 0 none).
ATRMaxSpacingPts - highest spacing in points (5000; 0 none).
ATRFreezeOnStart - keeps one spacing for the whole cycle (off).
Profit target
DesiredProfitPerClosure - base target in account currency (2.0).
ProfitMultiplier - final scale, 1.00 to 2.00.
ProfitTargetMode - scaled by default: bigger, deeper books aim higher.
ProfitVolumePower - how closing volume lifts the target (1.0; 0 off).
ProfitDepthBonus - extra target per additional open level (0.10).
ProfitMaxMultiple - scaled target ceiling in multiples of the base (50).
ProfitMaxReachFraction - keeps the target inside this share of one grid step (0.50).
Fragment scanner
UseMultiLegScan - checks multi-order groups before the plain pair (on).
MaxOldestLegs - most old orders in one closure (3).
MaxNewestLegs - most new orders in one closure (6).
ScanPriority - ranking of qualifying groups; largest group first by default.
NeverBankLessThanPair - a group must also beat the pair target (on).
RequireCloseVolumeExceedsTarget - newest volume must be above oldest volume (on).
MinCloseVolumeRatio - required ratio of those volumes (1.5).
Target slicing
EnableTargetSlicing - allows part-closing the oldest order (on).
FragProfitWeightPower - profit weight per closing lot (1.5).
FragMinSlicePercent - smallest slice, percent of the target order (20).
FragAllowMultiCloser - several new orders may fund one slice (on).
FragPreferFullClosure - a full closure wins when both are possible (on).
Reopen guard
ReopenGuard - blocks closures that would reopen a level at once (step based).
ReopenGuardCushion - safe distance as a share of one step (0.90).
Account protection
MinMarginLevelPercent - no new levels below this margin level (0 off).
MaxAccountRiskPercent - no new levels beyond this floating loss, percent of balance (0 off).
NetMaxMarginPercent - netting only: cap on net position margin, percent of equity (5.0).
MaxTotalOrders - absolute order cap per side (1000).
Execution and checks
RunMode - Armed or Scan only.
CloseSequence - order in which legs are sent; oldest first by default.
MaxSlippagePoints - allowed slippage (30).
MaxSpreadPoints - no trading above this spread (7500).
MinSecondsBetweenClosures - pause between closures per side (5).
CloseAttemptsPerLeg - attempts before the retry queue (3).
VerifyTimeoutSeconds - how long a stuck leg is followed (90).
DeferWhenMarketClosed - waits for the session instead of halting (on).
MarketClosedRetrySeconds - retry spacing while orders are refused (30).
AutoResumeAfterSeconds - a halt clears itself after this many seconds (300; 0 waits for you).
NoPartialRetryMinutes - partial closes tried again this many minutes after a broker refusal (15; 0 never).
AbortIfBookChanged - drops a plan if a leg changed (on).
UseFullCommission - counts commission on both sides (on).
CommissionPerLot - fallback figure (0 reads history).
CloseOrderComment - text on closing deals.
Hedge cycle
EnableHedgeCycle - main switch (off).
HedgeSymbols - comma list; repeat a symbol for more turns (XAGUSD).
HedgeSymbolRotation - how the next symbol is picked (per cycle).
HedgeMaxSymbolsInTester - rotation cap in the tester only (2; 0 none).
HedgeCycleLots - lots on each side of the pair (0.01).
HedgeSliceLots - lots retired per side each slice (0.01).
HedgeFragmentBonus - bonus over the slice cost (100).
HedgeBonusIsPercent - bonus is a percent; false means money (on).
HedgeMaxSurcharge - money cap per closure (0 none).
HedgeMaxSurchargePercent - largest rise of any closure target, percent (50).
HedgeMagicNumber - number on hedge legs, must differ from the grid (9768841).
HedgeReopenOnFinish - opens a new cycle when one ends (on).
HedgeStartRequiresTrade - first cycle waits for a grid order (on).
HedgeIntegritySeconds - leg balance check interval (5).
HedgeAutoRepair - repairs a lone leg automatically (on).
HedgeNakedAction - what to do with a lone leg; re-hedge by default.
HedgeMaxSpreadPoints - hedge spread limit (0 off).
HedgeSlippagePoints - hedge slippage allowance (30).
HedgeAttemptsPerLeg - attempts per hedge leg (3).
HedgeVerifyTimeout - follow time for a stuck hedge leg (90).
HedgeCommissionPerLot - fallback hedge commission (0 reads history).
HedgeOrderComment - text on hedge deals.
Weekly cash day
WeeklyCashDay - pauses new cycles and slices around withdrawals (off).
CashDayOfWeek - 0 Sunday, 1 Monday and so on (1).
CashCutoffHour - server hour after which no new slice fires (21).
Panel and chart
ShowPanel - panel on or off.
PanelX and PanelY - distance from the chart edge (12, 15).
PanelFontSize - base text size (9).
ShowArabic - second language line (on).
ShowChartMarks - plans and levels drawn on the chart (on).
MaxTableRows - order rows per grid (13).
PanelCorner - corner the panel is anchored to.
Entry trigger
EntryTriggerMode - the Coppock strategy by default.
SignalBarShift - 1 is the last finished bar.
SignalBarsDelay - bars between accepted signals (30; 0 every).
SignalValidBars - bars a signal stays usable (3).
SignalAllowBuy and SignalAllowSell - switch each side.
SignalReverse - turns the direction around (off).
Coppock Curve
InpCPKRocLong - long rate of change in bars, above the short one (14).
InpCPKRocShort - short rate of change in bars (11).
InpCPKWMA - length of the weighted average that turns the two ROC values into the curve (10).
InpCPKMode - 1 hook (turn after a fall below zero / a rise above zero), 0 zero line cross (1).
InpCPKHookBars - hook mode: bars the curve must have fallen before a BUY turn or risen before a SELL turn (2).
InpCPKDepthMin - Depth Guard: least distance past zero at the turn, in Coppock percent (0 off; try 0.15 on EURUSD).
InpCPKRangeMinATR - Range Guard: least window width in ATR (5; 0 off).
InpCPKRangeBars - Range Guard: window length in bars (20).
InpCPKATRPeriod - ATR length for the Range Guard (14).
InpCPKTrendFilter - 1 with the EMA side, 2 against it, 0 off (1).
InpCPKTrendMAPeriod - trend EMA length (200).
InpShowSignalArrows - arrow where a cycle armed (on).
InpShowCPKOnChart - past hooks on the live chart, arrow or grey dot (on).
Debug
DebugMode - extra journal detail (off).
Margin timeframe safety
UseMarginTFSafety - main switch (off).
Level1MarginPct and Level1TF - at 6000 percent the work moves to M15.
Level2MarginPct and Level2TF - at 5000 percent the work moves to H1.
MarginTFHysteresisPct - recovery needed before stepping back (500).
----------
Risk, plainly
Grid trading is risky. It adds to losing positions, uses no stop loss, and a long trend can keep the book open for a long time or, with lots too big for the balance, end in a stop-out and a heavy loss. The Coppock Curve is built from past prices and cannot see the next bar. No profit is promised. Pick lots that survive a bad run, test on your own broker, and only risk money you can afford to lose. No DLLs or extra files are needed.
If you use it, please leave an honest review of how it behaved for you, good or bad; it helps the next trader decide.
