MODIFICAR UN INDICADOR Y CREAR UN EA // MODIFY AN INDICATOR AND BUILD AN EA

MQL5 Indicateurs Experts

Spécifications

Desearía modificar un indicador que ya tengo que dibuja las líneas de tendencia uniendo los 2 últimos fractales de Bill Williams resistencia (los que se encuentran por encima del precio actual) y los 2 últimos soporte (los que se encuentran por debajo), con la única condición que buscando de derecha a izquierda el segundo fractal, ya sea soporte o resistencia, tiene que ser el siguiente fractal por debajo del primero.

Adjunto el indicador que se denomina Demark_Trendline_Trader, al cual habría que corregir las líneas de SL y TP conforme a las reglas que se adjuntan y modificar la alarma para que avise en la apertura de la segunda vela que haya roto la línea de tendencia.

Las líneas que se dibujan deben unir las mechas, no el cuerpo de las velas.


 






                                                                               

  

Stop Loss: en el indicador que se facilita son las líneas horizontales roja y verde. Se trata de modificarlas para que se sitúen, en un Buy, el SL estaría 1 pip por debajo de la mecha del último fractal soporte, y en un Sell, al revés.

 

SL en un Buy                                                                 SL en un Sell                     


Take Prfit: se sitúa, en un Buy, midiendo la distancia desde el punto inicial más alto de la línea bajista (el fractal resistencia más alto de los 2 que usamos para dibujar la línea de tendencia) con la cotización inferior mínima (el fractal soporte más bajo). El TP es la distancia, medida como se ha indicado, desde la primera vela que rompe la línea y cuyo cierre esté por debajo de la línea. En ese punto de dibujaría una línea horizontal verde, color SeaGreen. En un Sell, al revés, y la línea sería color Tomato.

  TP en un Buy                                                                 TP en un Sell         


 

 

Alarmas: están establecidas en la rotura de la línea de tendencia, y habría que modificarlas para que avise en la apertura de la segunda vela que haya roto la línea de tendencia.

 

2ª fase

 

Una vez creado el indicador, se haría el EA, que incluiría también 2 indicadores que se adjuntan, el PSC-Trader para gestión monetaria, y el Quiktrailing, para establecer los SL, TP y Trailing Stops.

 

Señal de compra: en un Buy, la apertura de la siguiente vela a la que ha roto la línea de tendencia, cerrando por encima de ella. Señal de venta: Al revés.

 

Take Profit: que se pueda definir si es el 100 % de la distancia antes señalada, u otro porcentaje.

 

Filtro adicional: Este filtro podrá activarse (True) o desactivarse (False). True: Abriría sólo aquellas operaciones que cumplieran con el ratio Riesgo/Beneficio que se fije. Default: 1,00, abriría un Buy o Sell si la relación riesgo beneficio es de 1:1 como mínimo, pudiendo fijar este parámetro en lo que se desee.

 

Filtro adicional: True/False. En un Buy que abra la posición siempre y cuando, además de lo señalado, la segunda vela cierre por encima de los labios del indicador Alligator de Williams. Default: False.

 

Se definirán estos colores para las 3 líneas del Alligator como default:


 

 

Filtro adicional: True/False. Abriría aquellas operaciones en las que el activo estuviera en tendencia. Los inputs consistirían en:

 

Poder establecer los TFs en los que se opera. Default: 1H y 4H.

 

Poder establecer la media móvil a usar, por ejemplo, la media móvil simple, exponencial o ponderada que se desee, como default, media móvil ponderada de 200. True/False

 

Si tuviera la media indicada en ambos TFs pendientes positivas, abriría un Buy, o si ambas fueran negativas, abriría un Sell.

 

PSC-Trader modificaciones:

 

Que el riesgo por trade como default sea 0,5 %.

 

Añadir un riesgo total de la cartera, justo debajo del riesgo por trade, en porcentaje y más abajo en euros. Tendría en cuenta todas las posiciones abiertas, fijándolo como default un  6 % (si superara esa cifra no abriría más posiciones, salvo que se cambie es valor por otro porcentaje).

 

Las líneas por defecto Lime, Yellow y Blue, serán Tomato, SeaGreen y Black, y el tipo de letra como default Verdana en vez de Courier.

 

Quiktrailing modificaciones:

 

Que el SL y el TP también puedan definirse también en €.

 

El First_TakeProfit_At también se tendría que:

 

Poder definir en euros.

 

Si de todas las posiciones abiertas, cada trade que llegue llega a 500 euros que se cierre (default). True and False.

 

Que permita también cerrar todas las operaciones en su conjunto si llegan a un determinado importe, por ejemplo, 1.000 € (default).  True and False.

 

Horario:

 

El EA tendría que poder operar en el horario que se determine con sus correspondientes inputs, pueda activarse (“true”) o desactivarse (“false”). Debido a que esta estrategia suele funcionar mejor en la apertura del mercado europeo, que se pueda definir:

 

Si se opera la sesión europea, estableciendo un horario, por ejemplo, de 8 - 11.30 h y GMT+1. True/False.

 

Si se quiere operar la sesión americana, poder establecer el horario, por ejemplo, de 15.30 – 18.30 y el huso horario, por ejemplo,  GMT + 1. True/False. Default: el horario señalado.

 

Poder especificar la hora en la que se desee cerrar todas las posiciones abiertas. Default: 18.30 h GMT + 1, DST Europe.

Gracias, saludos,


---------------------------------------------------------------------------------------------------------------------------------------------------


 

I would like to modify an indicator that I already have that draws the trend lines joining the last 2 fractals of Bill Williams resistance (those that are above the current price) and the last 2 supports (those that are below), with the only condition that looking from right to left the second fractal, either support or resistance, must be the next fractal below the first.

 

Attached is the indicator called Demark_Trendline_Trader, to which the SL and TP lines would have to be corrected according to the attached rules and the alarm should be modified to warn at the opening of the second candle that it has broken the trend line.

 

The lines that are drawn should join the wicks, not the body of the candles.

 

 

 

 

Line that joins the last 2 supporting fractals                        Line that joins the last 2 supporting fractals resistance, the second fractal is the first on the right to the left which is below                is the first on the right to the left which is above the initial fractal

the initial fractal

 

Stop Loss: in the indicator provided are the horizontal red and green lines. It is about modifying them so that they will be located, in a Buy, the SL would be 1 pip below the wick of the last fractal support, and in a Sell, the other way around.

 

SL in a Buy                                            SL in a Sell

 

 

 

 

 

Take Profit: located, in a Buy, by measuring the distance from the highest starting point of the bearish line (the highest resistance fractal of the 2 that we use to draw the trend line) with the lowest lower price (the most supportive fractal, the one lower). The TP is the distance, measured as indicated, from the first candle that breaks the trend line and whose close price is below that trend line. At that point it will draw a green horizontal line, color SeaGreen. In a Sell, backwards, and the trend line would be Tomato color.

 

TP in a Buy                                            TP in a Sell

 

 

Alarms: they are established when the trend line breaks in the indicator proived. They must be modified to warn at the opening of the second candle which has broken the trend line.

 

2nd phase

 

Once the indicator was created, the EA would be done. It will consist of 3 indicators: the one which has just be modified and also include 2 attached indicators, the PSC-Trader for monetary management, and the Quiktrailing, to establish the SL, TP and Trailing Stops.

 

Buy signal: in a Buy, the opening of the next candle which the trend line has broken, closing above it. Sell ​​sign: Backwards.

 

Take Profit: that can be defined if it is 100% of the afore mentioned distance, or another percentage.

 

Additional filter: This filter can be activated (True) or deactivated (False). True: It would open only those operations that meet the Risk / Benefit ratio that is set. For example, you would open a Buy or Sell if the risk benefit ratio is at least 1: 1, and you can set this parameter as desired.

 

Additional filter: True / False. In a Buy that opens the position Buy, in addition to what has been indicated, the second candle closes above the lips of the Williams Alligator indicator. Default: False.

 

These colors will be defined for the 3 lines of the Alligator as default:

 

 

 

Additional filter: True / False. It would open those operations in which the asset is trending. The inputs would consist of:

 

To be able to establish the TFs in which it operates, for example, TF 4H and TF 1H (default).

 

Be able to set the moving average to use, for example the desired simple, exponential or weighted moving average. Default: weighted moving average of 200. True / False

 

If it had the average indicated in both positive TFs pending, it would open a Buy, or if both were negative, it would open a Sell.

 

PSC-Trader modifications:

 

That the risk per trade as default is 0.5%.

 

Add a total portfolio risk just below the risk per trade, in percentage and lower in euros. It would take into account all open positions, setting it as a default of 6% (if it exceeded that figure, it would not open more positions, unless the value is changed by another percentage).

 

The default lines Lime, Yellow and Blue will be Tomato, SeaGreen and Black, and the font will be Verdana instead of Courier.

 

Quiktrailing modifications:

 

That the SL and the TP can also be defined in €.

 

The First_TakeProfit_At would also have to:

 

To be able to define in euros.

 

If of all the open positions, each trade that arrives reaches 500 euros that is closed (default). True and False.

 

It also allows closing all operations as a whole if they reach a certain amount, for example, € 1,000 (default). True and False.

 

Schedule:

 

The EA should be able to operate at the time determined with its corresponding inputs, it can be activated (“true”) or deactivated (“false”). Because this strategy tends to work best in opening the European market, it can be defined:

 

If the European session is operated, establishing a schedule. Default: from 8 - 11.30 and GMT + 1 (DST Europe). True / False.

 

If you want to operate the American session, be able to set the hours. Default: from 15.30 - 18.30 pm and the time zone, GMT + 1 (DST Europe). True / False.

 

To be able to specify the time at which you want to close all open positions. Default: 18.30 GMT + 1 (DST Europe)-


Thanks. See you soon,

Dossiers :

Répondu

1
Développeur 1
Évaluation
(7)
Projets
9
22%
Arbitrage
0
En retard
0
Gratuit
2
Développeur 2
Évaluation
(253)
Projets
408
38%
Arbitrage
86
43% / 19%
En retard
70
17%
Travail
3
Développeur 3
Évaluation
(2)
Projets
3
33%
Arbitrage
1
0% / 100%
En retard
0
Gratuit

Informations sur le projet

Budget
50+ USD
TVA (21%): 10.5 USD
Total: 60.5 USD
Pour le développeur
45 USD