Adjustment to 'include' file to prohibit new trades for X bars if last X trades were loss-making

MQL4 Esperti

Lavoro terminato

Tempo di esecuzione 3 ore
Feedback del dipendente
All is good.

Specifiche

 

Hi,

 I use an 'include' file to manage trades, stop-losses and various other functions to manage the trading of my EA. I have recently experienced that some of my EAs, which otherwise produce solid returns - turn nasty for periods ranging from 5-40 periods, consecutively open trades and run into stop-losses. I want to prevent my EAs to trade for a defined period (should be variable) based on the following conditions: if over the last 20 bars (the number of bars should be smth, which can be set within the actual EA) if it did one or two loss-making trades in the same direction (Again, the number of permitted loss-making breaks). So it is meant to be function as a time-out for my EAs if it clearly does not produce valid signals! So to summarize the function

IF last X trades were loss-making in the last X bars, do not trade for X bars 

 Attached you will find the 'include' file I use and a random simple EA - I choose one which produces a substantial number of consecutive losses. Of course, I want to be able to amend any settings within the EA itself.   Please feel free to write if you need any further information.

 

Cheers,

 

Philipp 

 

 

Con risposta

1
Sviluppatore 1
Valutazioni
(215)
Progetti
302
79%
Arbitraggio
4
25% / 0%
In ritardo
62
21%
Gratuito
Pubblicati: 7 codici
Ordini simili
EA for RENKO 30+ USD
You are a professional MQL5 developer. Build a MetaTrader 5 Expert Advisor based strictly on Renko brick logic. ===================== RENKO ENGINE ===================== - Custom Renko calculation (no MT5 offline charts) - Brick size = user input (points) - Brick direction: +1 = bullish -1 = bearish - Use ONLY closed Renko bricks - No repainting - Single Renko engine used for trading + visuals =====================
Looking for a reliable Expert Advisor with a proven track record? I'm seeking an EA with source code that meets the following criteri *Requirements:* - .mq5 source code (well-commented and readable) - 4-year backtest (Jan 2022 - Dec 2025) with tick/data quality details - 1-month demo test on live/demo broker - ~15% monthly average returns (medium risk) - Max drawdown ≤15% (equity/drawdown report) - No grid
I’m looking to acquire an existing, profitable Expert Advisor (EA) with full source code to add to our client investment portfolio. To be clear, this is not a request to develop or design a new strategy . If you already have an EA that is proven, consistent, and production-ready , I’m open to reviewing it immediately. Please apply only if you meet all the requirements below . Submissions without a proper
I need a custom MT5 Expert Advisor named “Dark Venus”. Strategy details: - Timeframe: M5 / M15 - Market: Forex (all major pairs) - Strategy type: Trend + Scalping - Indicators: • EMA (Fast & Slow) • RSI filter • ATR for Stop Loss & Take Profit - Trades only during low-spread sessions (London & New York) Trade Rules: - Buy when fast EMA crosses above slow EMA + RSI confirmation - Sell when fast EMA crosses below
//+------------------------------------------------------------------+ //| FXE Trader Smart AI EA (Deriv MT5 Forex) | //+------------------------------------------------------------------+ #property strict #include <Trade/Trade.mqh> CTrade trade; // ===== INPUTS ===== input double RiskPercent = 1.0; // % risk per trade input int FastEMA = 50; input int SlowEMA = 200; input int RSI_Period = 14; input int
Acquire existing profitable Expert Advisor with source code for client investment portfolio - Full .mq5 code (clean & commented) - 4+ years backtest (Jan 2022 - Dec 2025, 100% tick data) - ~10% monthly return - Max DD ≤15% - No grid/martingale (strictly enforced) - 1-month forward test required - Send trade history + EA details for review - Demo EA file needed for backtest replication - Open to any currency
i need the multi-chain dex bot with set up and installation i need you to help me set the copy reading wallet on binance or phantom with capital for 100 Euro to 1 Million in one year
Please teach me orderflow 300 - 3000 USD
I am searching a profitable trader that is using orderflow in his analysis. Only serious offers please. Please send me your history of trades. I need proof. Merry Christmas everyone
Greetings, I'm seeking a price quote for the following EA description. 1) Short positions are opened after trades that have closed below the open of the trade. 2) Long positions are opened after trades that have closed above the open of the trade. 3) The base lot size plus the spread is applied for every trade that opens after the take profit has been reached. 4) Double the lot size of the previous trade plus
I have an issue with my ninja script and i would like you to help me straighten things I wanted to create an indicator and i have the source code already but i am getting compiling errors on my NinjaTrader And i tried fixing the error it still same I sent 3 images here for you to understand the errors and i would like to ask if you can help me fix it so i can go ahead and compile my source code. Thanks

Informazioni sul progetto

Budget
10 - 30 USD
Scadenze
da 1 a 5 giorno(i)