Partnum robot

MQL5 Asesores Expertos

Tarea técnica

//+------------------------------------------------------------------+ //| Enhanced_MA_Crossover.mq5 | //| Enhanced Moving Average Advisor | //+------------------------------------------------------------------+ #property copyright "Enhanced Example" #property link "MQL5 Code" #property version "2.00" // Include the Standard Library for trade operations #include //------------------------------------------------------------------ // INPUT PARAMETERS (USER SETTINGS) //------------------------------------------------------------------ // --- MA Settings --- input int Fast_Period = 10; // Fast MA Period input int Slow_Period = 50; // Slow MA Period input ENUM_MA_METHOD MA_Method = MODE_EMA; // MA Method (e.g., EMA) input ENUM_APPLIED_PRICE Price_Type = PRICE_CLOSE; // Price Type // --- Risk and Trade Settings --- input double Risk_Percentage = 1.0; // Risk per trade (% of Balance) input double Max_Lots = 1.0; // Maximum allowed Lot Size input int StopLoss_Points = 200; // Stop Loss in Points (200 = 20 Pips) input int TakeProfit_Points = 600; // Take Profit in Points (600 = 60 Pips) input int Trailing_Start_Points = 300; // Start Trailing when profit reaches (30 Pips) input int Trailing_Stop_Points = 150; // Trailing Stop distance (15 Pips) input ulong MagicNumber = 56789; // Unique EA Identifier //------------------------------------------------------------------ // GLOBAL OBJECTS //------------------------------------------------------------------ CTrade trade; // Object for trade execution // Indicator handles int g_ma_handle_fast; int g_ma_handle_slow; //+------------------------------------------------------------------+ //| OnInit: Initialization function | //+------------------------------------------------------------------+ int OnInit() { // Setup CTrade object trade.SetExpertMagicNumber(MagicNumber); trade.SetMarginMode(); // Get indicator handles g_ma_handle_fast = iMA(_Symbol, _Period, Fast_Period, 0, MA_Method, Price_Type); g_ma_handle_slow = iMA(_Symbol, _Period, Slow_Period, 0, MA_Method, Price_Type); // Check if handles are valid if(g_ma_handle_fast == INVALID_HANDLE || g_ma_handle_slow == INVALID_HANDLE) { Print("Failed to load iMA indicators. EA failed to start."); return(INIT_FAILED); } Print("EA Initialized Successfully with Risk: ", Risk_Percentage, "%"); return(INIT_SUCCEEDED); } //+------------------------------------------------------------------+ //| OnTick: Main execution function | //+------------------------------------------------------------------+ void OnTick() { // Check for trade signals first CheckForSignalAndOpenTrade(); // Then manage existing trades ManagePositions(); } //+------------------------------------------------------------------+ //| Custom Function: Check for Signal and Open Trade | //+------------------------------------------------------------------+ void CheckForSignalAndOpenTrade() { // Exit if a position is already open for this symbol if (PositionSelect(_Symbol) == true) { return; } MqlTick tick; if(!SymbolInfoTick(_Symbol, tick)) return; double ask = tick.ask; double bid = tick.bid; double point = SymbolInfoDouble(_Symbol, SYMBOL_POINT); // --- Get MA Values from the last CLOSED bar (Index 1) --- double fast_ma[2], slow_ma[2]; // Need 2 values for crossover logic // Copying data for the two latest bars (current=0, previous=1) if(CopyBuffer(g_ma_handle_fast, 0, 0, 2, fast_ma) <= 0 || CopyBuffer(g_ma_handle_slow, 0, 0, 2, slow_ma) <= 0) { return; } // Crossover Logic using the previous bar (Index 1) and the bar before that (Index 0 in the array) // fast_ma[1] is the MA value from the last completed bar. // fast_ma[0] is the MA value from the bar currently forming. // --- CHECK FOR BUY CROSSOVER --- // Fast MA crosses above Slow MA (Previous bar: Fast was below Slow, Current bar: Fast is above Slow) if (fast_ma[1] > slow_ma[1] && fast_ma[0] <= slow_ma[0]) { double lot_size = CalculateLotSize(StopLoss_Points * point); double sl_price = NormalizeDouble(bid - StopLoss_Points * point, _Digits); double tp_price = NormalizeDouble(bid + TakeProfit_Points * point, _Digits); // Open BUY Trade trade.Buy(lot_size, _Symbol, ask, sl_price, tp_price, "MA Crossover BUY"); } // --- CHECK FOR SELL CROSSOVER --- // Fast MA crosses below Slow MA (Previous bar: Fast was above Slow, Current bar: Fast is below Slow) else if (fast_ma[1] < slow_ma[1] && fast_ma[0] >= slow_ma[0]) { double lot_size = CalculateLotSize(StopLoss_Points * point); double sl_price = NormalizeDouble(ask + StopLoss_Points * point, _Digits); double tp_price = NormalizeDouble(ask - TakeProfit_Points * point, _Digits); // Open SELL Trade trade.Sell(lot_size, _Symbol, bid, sl_price, tp_price, "MA Crossover SELL"); } } //+------------------------------------------------------------------+ //| Custom Function: Calculate Lot Size based on Risk % | //| This is the Money Management part | //+------------------------------------------------------------------+ double CalculateLotSize(double risk_distance) { if (risk_distance <= 0) return 0.01; // Safety check // 1. Calculate Maximum Risk Amount in currency double balance = AccountInfoDouble(ACCOUNT_BALANCE); double max_risk_amount = balance * (Risk_Percentage / 100.0); // 2. Calculate the Value of 1 Lot in the account currency for the Stop Loss distance double tick_value = SymbolInfoDouble(_Symbol, SYMBOL_TRADE_TICK_VALUE); double tick_size = SymbolInfoDouble(_Symbol, SYMBOL_TRADE_TICK_SIZE); // Value of 1 Standard Lot (100,000 units) risked double one_lot_risk_value = risk_distance * (tick_value / tick_size); // 3. Calculate Lot Size double lot_size = max_risk_amount / one_lot_risk_value; // 4. Normalize and Cap Lots double min_lot = SymbolInfoDouble(_Symbol, SYMBOL_VOLUME_MIN); double lot_step = SymbolInfoDouble(_Symbol, SYMBOL_VOLUME_STEP); // Normalize to the volume step lot_size = MathRound(lot_size / lot_step) * lot_step; // Apply min and max limits lot_size = MathMax(min_lot, lot_size); lot_size = MathMin(Max_Lots, lot_size); return NormalizeDouble(lot_size, 2); } //+------------------------------------------------------------------+ //| Custom Function: Manage Positions (Trailing Stop) | //+------------------------------------------------------------------+ void ManagePositions() { // Iterate through all open positions for(int i = PositionsTotal() - 1; i >= 0; i--) { ulong position_ticket = PositionGetTicket(i); string symbol = PositionGetString(POSITION_SYMBOL); ulong magic = PositionGetInteger(POSITION_MAGIC); // Process only positions for the current symbol and current EA if (symbol != _Symbol || magic != MagicNumber) continue; long type = PositionGetInteger(POSITION_TYPE); double open_price = PositionGetDouble(POSITION_PRICE_OPEN); double sl = PositionGetDouble(POSITION_SL); MqlTick tick; if(!SymbolInfoTick(symbol, tick)) continue; double current_price = (type == POSITION_TYPE_BUY) ? tick.bid : tick.ask; double point = SymbolInfoDouble(symbol, SYMBOL_POINT); // Calculate current profit in points int current_profit_points = (int)MathRound(MathAbs(current_price - open_price) / point); // Check if trailing is necessary if (current_profit_points >= Trailing_Start_Points) { double new_sl_price = 0.0; if (type == POSITION_TYPE_BUY) { // For BUY: New SL must be at least Trailing_Stop_Points below current BID price new_sl_price = NormalizeDouble(tick.bid - Trailing_Stop_Points * point, _Digits); // Move SL only if the new SL is higher than the current SL if (new_sl_price > sl) { trade.PositionModify(position_ticket, new_sl_price, PositionGetDouble(POSITION_TP)); Print("BUY Position #", position_ticket, " Trailed SL to ", new_sl_price); } } else // POSITION_TYPE_SELL { // For SELL: New SL must be at least Trailing_Stop_Points above current ASK price new_sl_price = NormalizeDouble(tick.ask + Trailing_Stop_Points * point, _Digits); // Move SL only if the new SL is lower than the current SL if (new_sl_price < sl || sl == 0.0) // Also set SL if it's 0.0 { trade.PositionModify(position_ticket, new_sl_price, PositionGetDouble(POSITION_TP)); Print("SELL Position #", position_ticket, " Trailed SL to ", new_sl_price); } } } } } //+------------------------------------------------------------------+ //| OnDeinit: Deinitialization function | //+------------------------------------------------------------------+ void OnDeinit(const int reason) { // Clean up if needed }

Han respondido

1
Desarrollador 1
Evaluación
(257)
Proyectos
381
25%
Arbitraje
23
61% / 22%
Caducado
1
0%
Trabaja
2
Desarrollador 2
Evaluación
(11)
Proyectos
14
0%
Arbitraje
1
0% / 100%
Caducado
3
21%
Libre
3
Desarrollador 3
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
4
Desarrollador 4
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
Ha publicado: 2 artículos
5
Desarrollador 5
Evaluación
Proyectos
0
0%
Arbitraje
0
Caducado
0
Libre
6
Desarrollador 6
Evaluación
(5)
Proyectos
4
25%
Arbitraje
1
0% / 100%
Caducado
0
Libre
Solicitudes similares
MT5 EA 30+ USD
Here is the full strategy and all requirements for my custom MT5 EA. Please follow everything exactly as written. --- 📛 EA Name: PYTHON SWING TRADER ROBOT Must appear on the top-left corner of the chart Bold black text, clearly visible against orange background --- 🟧 CHART SETTINGS: Background Color: Orange Foreground (text & axes): Black Candlesticks: Black Grid: OFF Zoom: Always fully zoomed out > EA must enforce
Robot 50+ USD
The most advanced mobile robot 98 % wine fully automated it must work both mt4 and mt5 with any broker it must be able to trade small amount to big amount
I'm looking for an upgrade of existing 100% working tool (EA) which is NOT opening any positions, neither modifying opened positions, nor closing them. Instead, entire 100% working with zero bugs tool is based on providing alerts from multi time frame analysis I need some additional features to be implemented. Budget can be further negotiable. I look for few upgrades (additions) to my existing tool named Candle
Megasam bot 30+ USD
create an mt5 trading bot follow the trend that works on xauusd, gbpusd,and gbpjpy using ict, smc, and candle range theory concepts - taking trades after mitigating an order block or FVG look for cisd or choch after liquidity has been cleared then execute - take profit and stop loss in 1:2 risk to reward adjustable - editable risk percentage - work on all timeframe - with editable trailing stop loss only after 1:1 rr
Good Day, The scope of work is to implement the news history filter on 8 EAs. Logic should be implemented on each EA but is not working. Additionaly I would like to have the debug printed for the number of news event loaded and showing when EA is not operating on backtesting due to news + script mentioning that a position ha been closed due to news. News history is read by CSV File
I am looking for an experienced MQL5 developer to create an Expert Advisor for MetaTrader 5 with the following features: 🔹 **Order Logic** * At the close of the previous candle, the EA places: * Buy Stop at the high. * Sell Stop at the low. * Option to add an offset in points to stop orders. 🔹 **Stop Loss** * SL of Buy Stop = entry level of Sell Stop (+ offset). * SL of Sell Stop = entry level of Buy Stop (+
I'd like an EA that places multiple buy and sell stop orders according to two base prices. Whenever the market hits the higher price, sell stop orders must be placed on the lower one. Whenever the market hits the lower price, buy stop orders must be placed on the higher one. Also, the current base prices must always be shown on screen and they must change as the market price drops or rises, according to the rules
I am looking for a developer experienced in MQL5 and/or Python to build a system that automatically replicates trades from the Vantage Copy Trading section (web/app only) into an external MT5 account (different broker) . Main requirements: The system must read trades (symbol, buy/sell direction, lot size, SL/TP) from the Vantage Copy portal (accessible only via mobile app or web browser). The same trades must be
Vortex Pro – Multi-Asset Scalping EA Unlock fast, precise, and professional trading with Vortex Pro, the ultimate scalping EA for MT4 & MT5. Trade Forex, Indices, and Metals with advanced price action, momentum, and breakout detection. Works on Windows, macOS, Android & iOS Fully compatible with any broker and symbol format Optimized for M1, M5, M15, M30, and H1 Advanced trade management: SL/TP, trailing stop
Cześć, szukam programisty MQL4 do stworzenia uniwersalnego eksperta (EA) opartego na Smart Money Concepts (SMC). EA ma działać na różnych instrumentach – złocie, indeksach, walutach – ale przede wszystkim na złocie. Kluczowe jest, żeby EA otwierał zlecenia idealnie w szczytach i dołkach, czyli w punktach zwrotnych rynku. Chodzi mi o to, by wejścia były maksymalnie precyzyjne, a nie spóźnione. EA powinien używać

Información sobre el proyecto

Presupuesto
30 USD
Plazo límite de ejecución
a 30 día(s)

Cliente

Encargos realizados1
Número de arbitrajes0