Part of a code to implement in my EA

작업 종료됨

실행 시간 5 시간
피고용인의 피드백
Great customer. and thanks for help.
고객의 피드백
Very good programmer and fast!

명시


Hello, 

I need a code to implement at my EA. 

Make sure you got every detail of the code and do not hesitate to contact me.

When my EA will call this function ( "int Moment()" ), the result of the code should be: +1 for UP trend, -1 for DOWN trend and 0 for NEUTRAL.


The following should be the parameters inputs:

input group             "MA"
input ENUM_TIMEFRAMES      MA_TimeFrame        = PERIOD_CURRENT;   // MA: TimeFrame
input int                  MA_Period     = 20;          // MA: Averaging Period
input int                  MA_Shift      = 0;           // MA: Shift
input ENUM_MA_METHOD       MA_Method     = MODE_SMA;    // MA: Smoothing Type
input ENUM_APPLIED_PRICE   MA_Applied_Price = PRICE_CLOSE; // MA: Type Of Price
input group             "VOLUME"
input ENUM_TIMEFRAMES      VOL_TimeFrame        = PERIOD_CURRENT;   // Volume: TimeFrame (Must be equal to MA TF).
input ENUM_APPLIED_VOLUME  Vol_Type       =   VOLUME_REAL;    // Volume: Type
input group             "GENERAL"
input int                  CalculateBars           =     300;     // Bars To Calculate
input int                  Moments_Average     =     20;      // Average of the Volume Moment


The function will calculate up to "x" last bars (CalculateBars = 300).

Every time 02 sequence bars (i and i+1) close (close price) above the MA trend line, it will initiate a new "moment" (UP trend), until 02 sequence bars close below MA trend line and initiate a new "moment" (DOWN trend this time).

So, when 02 sequence bars close above the MA trend line, the function will start to calculate the following data:

1) How many points is the diference between the value of the close price of the first bar of this "moment" and the close price value of the last bar. (Should be in points and always positive value) - "mov_distance"

2) The sum of the volume (real or tick) of all the bars that compose the "moment". - "vol_sum"

3) The result of the division from the sum of the volume and the distance of the bars movement. - "power = vol_sum / mov_distance"

This function will calculate it until the next 02 sequence bars close below the MA trend line.

When it happen, it will initiate a new "moment", but this time it will be a down trend. PS: Remember the "power" result must be always a positive value, because the "mov_distance" should be the result in points.


As we are calculating the last x bars (300 for example), it should happen a lot of mixed "moments" of up trends and down trends.

For each "moment" of this, the function code will save the results ("power") separately.

After that, it will calculate the average of all moments results. "Moments_Average". 


Now, the last part is:

If the value of the current "moment" is greater then the "Moments_Average", it will return +1 for up trend and -1 for down trend.

If the value of the current "moment" is minor of the "Movements_Average", it will return 0.

응답함

1
개발자 1
등급
프로젝트
0
0%
중재
0
기한 초과
0
무료
2
개발자 2
등급
(75)
프로젝트
124
44%
중재
14
29% / 50%
기한 초과
17
14%
무료
3
개발자 3
등급
(20)
프로젝트
28
7%
중재
0
기한 초과
3
11%
무료
4
개발자 4
등급
(2630)
프로젝트
3343
67%
중재
77
48% / 14%
기한 초과
342
10%
무료
게재됨: 1 코드
비슷한 주문
EA with Zones 30+ USD
Good day! I have an indicator .mq5 this indicator calculates and draw zones on the chart. My request is to add these specific zones drawn and calculated exactly as the indicator in the EA. A replicate behavior of the zones from the indicator to the EA. Thank you
Task Title Implement Martingale Lot Scaling Sync Between Master and Slave MT4 Trade Copier Background I am using a local master–slave trade copier setup with: 1 Master MT4 4 Slave MT4 terminals Trades are currently copied correctly (entry, direction, symbol, SL/TP). Lot size handling currently copies either: the exact master lot, or a fixed base lot defined on the slave (e.g., always 0.01 or 1.0). Problem When the
SyedAtif 30 - 40 USD
Then this EA will remain simple and clean , exactly following your core rules only: ✅ MA50 crosses Leading Span B → trade opens ✅ Opposite cross → trade closes ✅ No TP / SL ✅ Only one position at a time ✅ Entry only after candle close confirmation ✅ Final Simple MT5 Expert Advisor (English Specification) Entry Rules BUY Entry Open a Buy trade when: MA50 crosses above Leading Span B Trade is triggered only
Julismorfx-Bot 150 - 300 USD
Hello, I am looking for an MT5 Expert Advisor based on a reversal trading strategy . The EA must follow strict risk management and be suitable for prop firm rules . Key requirements: • Platform: MT5 • Pairs: USDJPY, GBPUSD, XAUUSD (multi-pair) • Strategy: Reversal only (H4 context + M15 entry) • Fixed risk per trade (default 0.5%, max 1%) • One trade per pair, max 2 trades total • Every trade must have Stop Loss and
I have a well-tested and profitable trading strategy that I personally use in live markets. I am looking for an experienced Algo/Trading Bot Developer who can convert this strategy into a fully automated trading bot. This is not a basic indicator or script. I need a professional-level trading automation system. What I need: • Convert my manual trading strategy into an automated bot • Bot should execute trades
Hi everyone, I’m currently working on a private automated trading software designed specifically for XAUUSD (Gold) . This is not a signal service and not a high-frequency robot. The focus is on controlled risk, patience, and capital protection . Key points (shared briefly, not promotional): Trades one cycle at a time (no overtrading) Uses pure price behavior (no EMA, no indicators) Built-in break even and trailing
I need a custom MT5 Expert Advisor + small backend bridge. The EA must: trade ONLY pending orders (BUY STOP / SELL STOP) support dual-trigger logic (one cancels the other) support fixed SL/TP, time-decay cancel, TP1 → BE communicate with a backend via HTTP (WebRequest) The backend: receives market snapshots from MT5 calls OpenAI API returns a structured JSON signal (numbers only) No strategy design needed – logic and
hello I want Semi EA developer who knows deep about martingale ,program and understand the market . MQL5 → Freelance → Search Keywords: Semi EA , Trade Manager , Manual Trade EA DM 3–5 devs directly Upwork Search: MT5 trade manager Invite only (private job) Telegram Groups: MQL5 Developers MT4 MT5 Coders
I need a developer for a trading robot that works on my phone. The idea of the trading system is as follows : market entries are performed when MACD's main and signal lines intersect in the current trend direction . 2. Trend is determined based on the Exponential Moving Average with the specified period (InpMATrendPeriod). If the current EMA value is greater than the previous one
Expert Advisor not taking trades automatically as expected Need to make sure logic is sound and effective Make sure it is optimized to trade crash and boom only Modify if necessary so that the EA can perform at its best It should provide 1 notification per trade/signal found

프로젝트 정보

예산
30 - 60 USD
기한
 1 일