EA in MQL4 using simple candle pivot patterns

Asesores Expertos

Trabajo finalizado

Plazo de ejecución 1 día
Comentario del Ejecutor
thank you, good work.

Tarea técnica

The idea:

To begin with this strategy has been tested with IT-charts backtesting method and gives about 50-50 of the trades either on the profit or the loss site. However the profitable trades generate around three times more profit than the loosing trades are causing losses. The end result gives a net profit after 3 months ideally (if all signals are executed at the very time they come out) at 2500 points given that all positions are open as 1. The method has been used for about a month for trading with DJIA and Forex (EUR/USD) at 2 hours and 4 hours charts respectivelly and due to practical reasons (i.e. not being able to execute all signals) ended up with lower profits than expected at around 400 points. The main problem as with many strategies is that an average person can not follow all signals as these are coming out on a 24/hour-basis.

The method is based on simple 3, 4 and 5 candle set patterns and defines a bearish or a bullish pivot points (trend reversal).

Example of 3 candle sets: (The candles are numbered as 2-1-0 with the 0 being the most recent one). We have a bullish pivot point whereas candle 1 has lower low than candle 2 and candle 1 has lower high than candle 2 and candle 0 crosses over the high of candle 1. The program should automatically exit all short positions should there are any open and automatically open a long position at the time of crossing without any manual intervention. Of course the reverse (i.e. sell all long positions and sell short simultaneously should be executed in case of a bearish signal).

I can provide all help that might be needed so that the developer gets a clear picture of what is needed. Please also see below the rules that I wrote in IT-chart build-in language if that helps.


The rules I am using in the IT-charts custom indicator, in case they are of any help are as follows:

ONCE S3 = 0
ONCE S4 = 0

ONCE S5 = 0


//NOTE: S3, S4 and S5 are sets of 3, 4 and 5 candles respectively

//NOTE: Values of the above can only take the values of 1 (for bullish, - 1 for bearish, or 0 (for no signal).

//NOTE: The following code defines the rules based on highs and lows of the involved candles:


IF LOW[0] < LOW[1] AND LOW[1] > LOW[2] AND HIGH[0] < HIGH[1] AND HIGH[1] > HIGH[2] THEN
    S3 = -1
ELSIF LOW[0] > LOW[1] AND LOW[1] < LOW[2] AND HIGH[0] > HIGH[1] AND HIGH[1] < HIGH[2] THEN
    S3 = 1
ELSE
    S3 = 0
ENDIF

IF LOW[0] < LOW[1] AND LOW[3] < LOW[1] AND HIGH[0] < HIGH[1] AND HIGH[3] < HIGH[1] AND HIGH[2] < HIGH[1] AND LOW[2] > LOW[1] THEN
    S4 = -1
ELSIF LOW[0] < LOW[2] AND LOW[3] < LOW[2] AND HIGH[0] < HIGH[2] AND HIGH[3] < HIGH[2] AND HIGH[1] < HIGH[2] AND LOW[1] > LOW[2] THEN
    S4 = -1
ELSIF LOW[0] > LOW[2] AND LOW[3] > LOW[2] AND HIGH[3] > HIGH[2] AND HIGH[0] > HIGH[2] AND HIGH[1] < HIGH[2] AND LOW[1] > LOW[2] THEN
    S4 = 1
ELSIF LOW[0] > LOW[1] AND LOW[3] > LOW[1] AND HIGH[0] > HIGH[1] AND HIGH[3] > HIGH[1] AND HIGH[2] < HIGH[1] AND LOW[2] > LOW[1] THEN
    S4 = 1
ELSIF LOW[0] < LOW[2] AND LOW[3] < LOW[2] AND HIGH[0] < MAX(HIGH[2],HIGH[1]) AND HIGH[3] < MAX(HIGH[2],HIGH[1]) AND LOW[1] = LOW[2] AND HIGH[0] < MAX(HIGH[1],HIGH[2]) THEN
    S4 = -1
ELSIF LOW[0] > MIN(LOW[1],LOW[2]) AND LOW[3] > MIN(LOW[1],LOW[2]) AND HIGH[0] > HIGH[1] AND HIGH[3] > HIGH[1] AND HIGH[2] = HIGH[1] AND LOW[3] > MIN(LOW[1],LOW[2]) THEN
    S4 = 1
ELSE
    S4 = 0
ENDIF

IF LOW[0] < LOW[2] AND LOW[4] < LOW[2] AND HIGH[0] < HIGH[2] AND HIGH[4] < HIGH[2] AND HIGH[1] < HIGH[2] AND HIGH[3] < HIGH[2] AND LOW[1] > LOW[2] AND LOW[3] > LOW[2] THEN
    S5 = -1
ELSIF HIGH[0] > HIGH[2] AND HIGH[4] > HIGH[2] AND LOW[0] > LOW[2] AND LOW[4] > LOW[2] AND LOW[1] > LOW[2] AND LOW[3] > LOW[2] AND HIGH[1] < HIGH[2] AND HIGH[3] < HIGH[2] THEN
    S5 = 1
ELSIF HIGH[1] > HIGH[0] AND HIGH[1] > HIGH[4] AND LOW[1] > LOW[0] AND LOW[1] > LOW[4] AND HIGH[2] < HIGH[1] AND HIGH[3] < HIGH[1] AND LOW[3] > LOW[1] AND LOW[2] > LOW[1] THEN
    S5 = -1
ELSIF HIGH[3] > HIGH[0] AND HIGH[3] > HIGH[4] AND LOW[3] > LOW[0] AND LOW[3] > LOW[4] AND HIGH[2] < HIGH[3] AND HIGH[1] < HIGH[3] AND LOW[1] > LOW[3] AND LOW[2] > LOW[3] THEN
    S5 = -1
ELSIF LOW[1] < LOW[0] AND LOW[1] < LOW[4] AND HIGH[1] < HIGH[0] AND HIGH[1] < HIGH[4] AND HIGH[2] < HIGH[1] AND HIGH[3] < HIGH[1] AND LOW[2] > LOW[1] AND LOW[3] > LOW[1] THEN
    S5 = 1
ELSIF LOW[3] < LOW[0] AND LOW[3] < LOW[4] AND HIGH[3] < HIGH[0] AND HIGH[3] < HIGH[4] AND HIGH[2] < HIGH[3] AND HIGH[1] < HIGH[3] AND LOW[2] > LOW[3] AND LOW[1] > LOW[3] THEN
    S5 = 1
ELSE
    S5 = 0

ENDIF


// The following part of the code checks the crossing event and gives the price at which the order should be executed. P for price.


ONCE P = 0

IF S3 = 1 THEN
    P = HIGH[1]
ELSIF S3 = -1 THEN
    P = LOW[1]
ELSIF S4 = 1 THEN
    P = MAX(HIGH[1],HIGH[2])
ELSIF S4 = -1 THEN
    P = MIN(LOW[1],LOW[2])
ELSIF S5 = 1 THEN
    P = MAX(MAX(HIGH[1],HIGH[2]),HIGH[3])
ELSIF S5 = -1 THEN
    P = MIN(MIN(LOW[1],LOW[2]),LOW[3])
ELSE
    P = 0
ENDIF

RETURN S as "signal", P AS "PRICE OF SIGNAL"

Han respondido

1
Desarrollador 1
Evaluación
(41)
Proyectos
124
34%
Arbitraje
32
13% / 75%
Caducado
53
43%
Libre
Solicitudes similares
EA for MQL5 30+ USD
EA based on Price action logic required. Further detail will be shared to the selected coder Price action logic with some additional parameters for entry and exit are required Experience coders can do this job easily
Hello Great developer . I have another project in mind though (I have the source code). This expert, when attached to a chart with an open trade with no TP and/or SL set, will create hidden SL/TP (broker does not know) of xx/yy pips from the entry price and when the said TP/SL is hit the trade should be closed. I want you to modify it such that the expert will continously scan all 28 pairs and check those trades with
I'm looking for a trading algorithm that can generate a 25-30% or more monthly return, ideally with stop-loss (SL) and take-profit (TP) built in for risk management. Here’s what I’m after: Consistent monthly profits around 25-30%. A solid SL and TP system to manage risk and lock in profits. Full source code and a guide on how to set it up and use it. Should work across different time frames and ideally
I need a new ea 1500+ USD
i need an ea to place pendings order for support resistans and fibo level. (H1 Period) trailing breakeven start look pips volume steps for each pendings order tp sl tp by indicator sl by indicator
Hi, I need a good experience developer , who can add some requirement to my existing EA, like find support & resistance levels using Fibonacci tool with customization retracement levels
- you should be able to explain the logic behind the entry points of the expert / indicator before commencing . - source code should be clean code . - Replication of phrases via copy and paste is prohibited . - please give a meaningful description . - Key Is the multiplier
Hi guys Unfortunately, the last dev couldn't make it. The pinescript is using renko blocks tweaked with the ATR. So you need to have a renko indicator to make this strategy work on MT5. I'll provide the source after: - You applied for the job. - You have shown your experience with converting pinescripts into mql5. - You will give me an honest feedback if it's possible to convert or not. I will also provide a whole
I'm looking for a trading algorithm that can generate a 25-30% monthly return , ideally with stop-loss (SL) and take-profit (TP) built in for risk management. Here’s what I’m after: Consistent monthly profits around 25-30%. A solid SL and TP system to manage risk and lock in profits. Full source code and a guide on how to set it up and use it. Should work across different time frames and ideally across multiple
Develop a profitable MQL5 trading bot for MetaTrader 5. Support BTCUSD, XAUUSD, and GBPJPY pairs on the M1 timeframe. Implement any effective strategies/algorithms with flexible order types. Include take-profit (TP) and stop-loss (SL) settings. Apply risk management to limit 3% of account balance. Provide full source code upon completion
Hi, I’m looking to develop an MQL5 expert advisor (EA) with the following specifications. Here’s the detailed breakdown of the features and functionalities I need: **Note**: For manual buy orders, please ensure that the trailing stop activates automatically. 1. **Manual Control and Basic Settings**: Please implement a manual start and stop function, including Buy and Sell buttons with adjustable lot sizes. This

Información sobre el proyecto

Presupuesto
15 - 30 USD
Para el ejecutor
13.5 - 27 USD
Plazo límite de ejecución
de 5 a 10 día(s)