Termos de Referência

//+------------------------------------------------------------------+
//|                                   Gohan Scalper provision.mq5    |
//|                           Advanced Multi-Timeframe Forex Robot   |
//+------------------------------------------------------------------+
#property copyright "Tshegofatso"
#property link      "https://www.mql5.com"
#property version   "1.00"
#property strict

#include <Trade/Trade.mqh>
CTrade trade;

//+------------------------------------------------------------------+
//| Input Parameters                                                |
//+------------------------------------------------------------------+
enum ModeType { CONSERVATIVE, BALANCED, AGGRESSIVE };
input ModeType TradeMode = BALANCED;
input double RiskPercent = 1.0;
input double DefaultStopLossPips = 20.0;
input double MaxLot = 2.0;

//+------------------------------------------------------------------+
//| Session Time Checking                                           |
//+------------------------------------------------------------------+
bool IsInTradingSession()
{
   MqlDateTime t;
   TimeToStruct(TimeCurrent(), t);
   int timeInMinutes = t.hour * 60 + t.min;

   return (timeInMinutes >= 60 && timeInMinutes <= 480)  ||  // Asian
          (timeInMinutes >= 480 && timeInMinutes <= 960) ||  // London
          (timeInMinutes >= 780 && timeInMinutes <= 1320);   // New York
}

//+------------------------------------------------------------------+
//| Trend Detection (D1)                                            |
//+------------------------------------------------------------------+
int GetMarketTrend()
{
   static int maFastHandle = iMA(_Symbol, PERIOD_D1, 20, 0, MODE_EMA, PRICE_CLOSE);
   static int maSlowHandle = iMA(_Symbol, PERIOD_D1, 50, 0, MODE_EMA, PRICE_CLOSE);

   double maFast[], maSlow[];
   if(CopyBuffer(maFastHandle, 0, 0, 1, maFast) < 1 ||
      CopyBuffer(maSlowHandle, 0, 0, 1, maSlow) < 1)
      return 0;

   if (maFast[0] > maSlow[0]) return 1;    // Bullish
   if (maFast[0] < maSlow[0]) return -1;   // Bearish
   return 0;                               // Sideways
}

//+------------------------------------------------------------------+
//| Break of Structure (M15)                                        |
//+------------------------------------------------------------------+
bool DetectBreakOfStructure()
{
   double highs[2];
   if(CopyHigh(_Symbol, PERIOD_M15, 1, 2, highs) < 2)
      return false;

   return highs[0] > highs[1];
}

//+------------------------------------------------------------------+
//| Confirmation Candle (M5)                                        |
//+------------------------------------------------------------------+
bool IsConfirmationCandle()
{
   double open[1], close[1], high[1], low[1];

   if(CopyOpen(_Symbol, PERIOD_M5, 0, 1, open) < 1 ||
      CopyClose(_Symbol, PERIOD_M5, 0, 1, close) < 1 ||
      CopyHigh(_Symbol, PERIOD_M5, 0, 1, high) < 1 ||
      CopyLow(_Symbol, PERIOD_M5, 0, 1, low) < 1)
      return false;

   double body = MathAbs(close[0] - open[0]);
   double range = high[0] - low[0];

   return (body > range * 0.5);
}

//+------------------------------------------------------------------+
//| Lot Size Calculation                                            |
//+------------------------------------------------------------------+
double CalculateLotSize(double stopLossPips)
{
   double balance = AccountInfoDouble(ACCOUNT_BALANCE);
   double riskAmount = balance * (RiskPercent / 100.0);
   double pipValue = SymbolInfoDouble(_Symbol, SYMBOL_TRADE_TICK_VALUE);
   double lotSize = riskAmount / (stopLossPips * pipValue);
   return MathMin(MaxLot, MathMax(0.01, NormalizeDouble(lotSize, 2)));
}

//+------------------------------------------------------------------+
//| Enter Buy Trade                                                 |
//+------------------------------------------------------------------+
void EnterBuyTrade(double lot, double stopLossPips)
{
   double sl = SymbolInfoDouble(_Symbol, SYMBOL_BID) - stopLossPips * _Point;
   trade.Buy(lot, _Symbol, 0, sl, 0, "Buy Entry");
}

//+------------------------------------------------------------------+
//| Enter Sell Trade                                                |
//+------------------------------------------------------------------+
void EnterSellTrade(double lot, double stopLossPips)
{
   double sl = SymbolInfoDouble(_Symbol, SYMBOL_ASK) + stopLossPips * _Point;
   trade.Sell(lot, _Symbol, 0, sl, 0, "Sell Entry");
}

//+------------------------------------------------------------------+
//| Expert Tick Function                                            |
//+------------------------------------------------------------------+
void OnTick()
{
   if(!IsInTradingSession()) return;

   int trend = GetMarketTrend();
   if(trend == 0) return;

   if(!DetectBreakOfStructure()) return;

   if(!IsConfirmationCandle()) return;

   double lot = CalculateLotSize(DefaultStopLossPips);

   if(trend > 0)
      EnterBuyTrade(lot, DefaultStopLossPips);
   else
      EnterSellTrade(lot, DefaultStopLossPips);
}

//+------------------------------------------------------------------+
//| OnInit and Timer Hooks                                          |
//+------------------------------------------------------------------+
int OnInit()
{
   EventSetTimer(60);
   return INIT_SUCCEEDED;
}

void OnDeinit(const int reason)
{
   EventKillTimer();
}

void OnTimer()
{
   // Reserved for advanced wave/fakeout/FVG logic
}

Arquivos anexados:

Respondido

1
Desenvolvedor 1
Classificação
(6)
Projetos
4
0%
Arbitragem
5
0% / 100%
Expirado
0
Livre
Pedidos semelhantes
Greetings to all, I need an experienced developer to modify and fix my strategy logic inside the OnTick() function. So that the EA works exactly the way my strategy works. You will be working with an already written MQL5 code , you will only be adjusting and modifying the logic to fit my specifications , you should have knowledge and experience working with ONNX m odels
🏆 HIRING: Quantitative Gold (XAU/USD) Trading Strategy Developer ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 📌 PROJECT OVERVIEW ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ I am building a professional trading signal platform (xtraderlab.com) and need an experienced quant trader or algo developer to design, code, and backtest a high-performance intraday Gold (XAU/USD) trading strategy. The strategy will be integrated into an existing
Technical Specifications: "Dawn Range Breakout" Expert Advisor (Final Version) 1. Overview The purpose of this EA is to capture the breakout of a specific hourly range on Gold (XAUUSD) or any other pair, with a focus on high-precision entry, strict risk management (1 trade per day), and partial profit taking. 2. Core Trading Logic Timeframe: M15. Reference Hour: The EA must identify the High and Low of the H1 candle
I need an Expert Advisor based on SK indicator for gold trading. Entry: - Open trade immediately when SK signal appears Stop Loss: - Fixed stop loss = $200 per trade Take Profit: - TP1: close 50% of the position - TP2: final target Lot Size: - Fixed lot = 0.02 Pair: - XAUUSD only Timeframe: - M15 Rules: - Only one trade per signal - No duplicate trades - Move stop loss to breakeven after TP1 Requirements: - The EA
Manly 30 - 200 USD
ZigZag based on oscillators is needed The idea of ​​the indicator Create a ZigZag indicator, which is constructed based on extreme values determined using oscillators. It can use any classical normalized oscillator, which has overbought and oversold zones. The algorithm should first be executed with the WPR indicator, then similarly add the possibility to draw a zigzag using the following indicators: CCI Chaikin RSI
AI Trading Bot 30 - 80 USD
Essential Components for Indicator Specification Objective & Overview: Briefly describe what the indicator calculates (e.g., trend, momentum, volatility) and its main purpose. Input Parameters (Variables): List all user-definable inputs (e.g., Moving Average periods, ATR multiplier) to avoid hardcoding values. Detailed Logic/Calculation Rules: Explain the formula or logic to calculate indicator values. Define
The basic idea of CRO is to simulate coral colonies that develop and compete for space on a reef, ultimately forming an optimal structure. Each coral in the reef represents a potential solution to the optimization problem under consideration. The reef is modeled as a two-dimensional N×M grid. Each grid cell can either be occupied by a coral or left empty. A coral is a coded solution to an optimization problem. For
Hi, I hope you’re doing great. I’d like to share the project details. The original EA is already working, but I need you to first review and verify that all existing features are functioning correctly. After confirming everything works properly, the next task is to add a simple user dashboard that shows the number of detected zones, buy/sell/none status, and includes an ON/OFF button. Also, please make sure that
looking for Expert to create or ready made solution for bonus hedge auto set cross trading of opposite trading strategy. the expert may guide what max and best he can do to make the EA perfect
Set specific time to run this function(order). The time can be hard-coded or inputted by user. Time format: HH:MM:SS:ss Example: 17:58:48:59 -> This means an order will be triggered at 5 pm 58min 48sec 59 today. Set “Stop loss” and order a Sell stop. “At price” triggered automatically: current(specific time set above 1) Gold price - 2$ Stop loss: current Gold price + 2$ Volume: 0.1 (It can be hard-coded or inputted

Informações sobre o projeto

Orçamento
30+ USD
Prazo
para 10 dias