Voir comment télécharger gratuitement des robots de trading
Retrouvez-nous sur Telegram !
Rejoignez notre page de fans
Un script intéressant ?
Poster un lien vers celui-ci -
laisser les autres l'évaluer
Vous avez aimé le script ? Essayez-le dans le terminal MetaTrader 5
Experts

87.8 Percent from 2021 to YTD at 8.5 Percent MaxDD. The Nikkei EA That Only Buys When Volume Is Quiet - expert pour MetaTrader 5

Tomasz Wojciech Forszpaniak
Tomasz Wojciech Forszpaniak
I started trading at 14 because I thought I had found an easy way to make money. Now 4 years later at 18, I’m an algorithmic trader obsessed with finding out whether an idea actually works.
Vues:
72
Publié:
MQL5 Freelance Besoin d'un robot ou d'un indicateur basé sur ce code ? Commandez-le sur Freelance Aller sur Freelance

JPN225 Quiet Drift

A free, fully open Nikkei 225 EA. It buys when price is leaning up, momentum isn't stretched and volume is unusually quiet, then closes everything by 17:00 server time. Three conditions, long only, one trade at a time, a stop loss on every trade.


Backtest results

Results1

-Net profit: +$8,782 (+87.8%, 10k account at 15lots)

-Return per year: +18.5% (simple, not compounded)

-Max drawdown: 8.5%

-MAR ratio: 1.17

-Profit factor: 1.68

-Win rate: 61.8% (191 of 309)

-Trades: 309, all long (about 65 a year)

-Average time in a trade: 3 h 48 min

-Recovery factor: 5.55


Every year was profitable: 2022 +15.6%, 2023 +18.1%, 2024 +22.3%, 2025 +16.4%, 2026 (to October) +15.4%.


Robustness: 15 tests built to break it

It passed all 15. The tests ran in my research engine. 

  • Costs and timing: doubled fees (PF 1.50), extra slippage (PF 1.30), every entry one bar late (PF 1.61).
  • Is it luck? p-value 0.0004 on the data used to build it and 0.011 on data it never saw. It beats 200 random-entry strategies (PF 1.75 vs 1.00). It stays significant after the Harvey-Liu haircut for the 385 candidates tried (adjusted p 0.014). 1,000 Monte Carlo resamples stay profitable.
  • Overfitting: held-out profit factor 1.81 vs 1.72 in-sample. 5 of 5 walk-forward periods profitable. Probability of backtest overfitting 8.6%. The look-ahead audit passed: no condition uses future data.
  • Fragility: all 12 nearby versions keep PF 1.10 or better, and all 54 setting tweaks stay profitable (median PF 1.45). Dropping a random 20% of trades, or the 10 best trades, still leaves a profit.


The strategy in more detail

A signal needs all three conditions on the bar that just closed:

1. Price is leaning up. The close is more than half a standard deviation above its 34-bar average.

2. Momentum is not stretched. The MACD histogram, in ATR units, is below 0.2. This only rules out strong upward surges.

3.Volume is quiet. Tick volume is below 60% of normal for that time of day (average of the last 20 days).


These came out of my automated research. I don't claim a theory for why they work, so the code is here for you to test and challenge.

Trade management: it buys at the open of the next bar with a stop at 4 ATR and a target at 3.5 ATR. Everything is closed by 17:00 server time. In the test, 63% of trades ended at the 17:00 close, 26% at the target and 11% at the stop.

When it trades: Monday to Friday. Signals are taken from 11:00 to 14:59 server time, so entries fall between 11:15 and 15:00, after Tokyo's cash session has closed. The times assume the common MetaTrader server time of GMT+2 in winter and GMT+3 in summer:

Entries Close
Server 11:15 to 15:00 17:00
New York 04:15 to 08:00 10:00
London 09:15 to 13:00 15:00
UTC 08:15 to 12:00 (summer), 09:15 to 13:00 (winter) 14:00 (summer), 15:00 (winter)

If your broker uses a different server time, move the hours by the difference. The EA prints your server's GMT offset when it starts.

Setup: attach it to your broker's Nikkei 225 chart (JPN225, JP225, NIKKEI225 and so on) on M15. Lot size is the main setting. The thresholds and hours are inputs if you want to experiment. The VALIDATION section at the bottom of the source exists only for MQL5's automatic tests and doesn't touch a trade on JPN225 M15.


Pros and cons

Pros

  • Three plain conditions in readable code
  • Profitable in every calendar year tested
  • Passed 15 stress tests
  • Stop loss on every trade, and flat by 17:00 (no overnight positions, no swap)
  • Free, with the full source

Cons

  • Long only, so it can go months without a trade
  • A fixed lot means dollar risk grows as the index rises (the average trade moved about $92 in 2022 and about $256 in 2026)
  • The volume condition uses tick volume, which depends on your broker's feed
  • One market and one timeframe


I don't trade this strategy myself. It's free research to read, test and build on. If you want to see the strategies I do trade, check my profile.

Shared for education and research. Backtest and stress-test results do not guarantee future performance. Only trade with money you can afford to lose.

Tick Integrity Auditor Tick Integrity Auditor

Audits the tick history that 'Every tick based on real ticks' backtests replay. Five checks per symbol over the last N days: impossible and crossed quotes, timestamps that run backwards or repeat, one-tick price reversals sized in multiples of the symbol's own median spread, silences inside the broker's declared quote sessions, and minutes where the ticks and the M1 bars disagree. Every finding goes to CSV with its millisecond timestamp, and the tool prints its own arithmetic so the report can be recounted. Read only: no trade function, no DLL, no network.

Memory Sequence Memory Sequence

A specified moment in time can be analyzed through multiple synced timeframes from 1 host chart for a symbol.

Extrapolator Extrapolator

Extrapolator fits a sum of sinusoidal harmonics to the recent price history and extends the fitted curve to the right of the last bar as a forecast.The forecast is a mathematical extrapolation of past cyclical behaviour, not a guarantee of future price movement. The last part of the line is redrawn while the current model bar is forming, and the fitted curve changes with each refit.

Market Activity from Quote Waits Market Activity from Quote Waits

Measures market activity from the waits between quotes. An ACD model with the daily rhythm removed gives one ratio per tick: 1 is normal, 2 twice as busy.