HHLL channel breakout strategy EA

Техническое задание

MetaTrader 4 (MT4) script that implements a channel breakout strategy. This script will use the "HHLLIndicator" and "Average Daily Range (ADR)" indicators to make trading decisions.

Logic Overview:
Indicators: The script will utilize two custom indicators: "HHLLIndicator" to identify Highest High (HH) and Lowest Low (LL) and "ADR" to calculate the Average Daily Range.

Timeframe: The strategy will be applied on the 15-minute (M15) chart.

Entry Conditions:

Average Daily Range (ADR) Check: The script will calculate the ADR using the "ADR" indicator. If the ADR is greater than or equal to 100 pips, the script will proceed with the strategy. Otherwise, it will not trade.

HH and LL Calculation: The "HHLLIndicator" will be used to calculate the Highest High (HH) and Lowest Low (LL) on the 15-minute chart.
Entry Levels: The script will calculate entry levels for both long (buy) and short (sell) positions.
Buy Stop: Above the HH by a specified number of pips.
Sell Stop: Below the LL by a specified number of pips.
Pending Orders:

The script will check for existing pending orders and delete them to avoid duplication.
Order Placement:
The script will place pending buy-stop and sell-stop orders at the calculated levels.
Trailing Stop:

If the Trailing Step Stop is enabled (not set to -1), the script will not set trailing stops.
If the Trailing Step Stop is set to -1, the script will set trailing stops for both buy and sell orders. The trailing stop will initially be set at "TrailingStopStart" pips, and it will step by "TrailingStepSteps" pips as the price moves in favor of the trade.
Detailed Task:
Create a new script in MetaEditor and name it "ChannelBreakout.mq4."
Define the necessary input parameters at the beginning of the script. These parameters include:

StopLoss: Stop Loss in pips (0 for automatic calculation).
TakeProfit: Take Profit in pips (0 for automatic calculation).
ADRThreshold1: ADR threshold for the first condition (e.g., 100).
ADRThreshold2: ADR threshold for the second condition (e.g., 175).
EntryOffsetPips: Offset for entry orders (e.g., 10).
EntryHourGMT: Hour to enter pending orders in GMT time (e.g., 23).
RiskRewardRatio: Risk-reward ratio (e.g., 3.0).
TrailingStopStart: Initial Trailing Stop in pips (e.g., 30).
TrailingStepSteps: Trailing Step in pips (e.g., 20).
TrailingStepStop: Trailing Step Stop (use StopLoss or set to -1 for trailing) (e.g., -1).
MagicNumber: Magic Number for orders (e.g., 0).
BuyStopAboveLL: Buy Stop Offset above Lowest Low in pips (e.g., 10).
SellStopBelowHH: Sell Stop Offset below Highest High in pips (e.g., 10).
In the "OnInit" function, create handles for the "HHLLIndicator" and "ADR" indicators. These handles will allow you to access the indicator values later.

In the "OnDeinit" function, delete the indicator handles to free up resources.

In the "OnTick" function, implement the trading logic based on the steps mentioned in the logic overview. Specifically:

Calculate the ADR using the "ADR" indicator on the 15-minute chart.
Check if ADR is greater than or equal to "ADRThreshold1." If not, do not proceed with trading.
Calculate HH and LL using the "HHLLIndicator" on the 15-minute chart.
Calculate entry levels for buy and sell orders based on HH, LL, BuyStopAboveLL, and SellStopBelowHH.
Check for existing pending orders and delete them.
Place pending buy-stop and sell-stop orders at the calculated levels.
If "TrailingStepStop" is set to -1, set trailing stops for both buy and sell orders.
Create a function to delete pending orders called "DeletePendingOrders." This function should iterate through existing orders and delete buy-stop and sell-stop orders.

Create a function to set trailing stops called "SetTrailingStop." This function should calculate the appropriate trailing stop level based on the current price and trailing parameters.
Save and compile the script.
Attach the "ChannelBreakout.mq4" script to a 15-minute chart in MetaTrader.
Ensure that the "HHLLIndicator" and "ADR" indicators are properly installed and available in MetaTrader.
Test the script in a demo account to ensure it behaves as expected and follows the defined logic.

The strategy now it has erros and dont work as should
In the atachment you have all teh script and the EA the chart must display the
ADR =day value
Details aboout postions
Positions
SL
TP
Working/Slipping
Must work on any time frame and calculate the ADR

HH and LL lines above the candle
I need to know how long you need and how much you want to be pay the job is for 2-3 h max

Debug report
back testing report
No errors or warning

Zomm and  interview  is  amust before job will be acceptd

Файлы:

Откликнулись

1
Разработчик 1
Оценка
(24)
Проекты
31
16%
Арбитраж
7
29% / 43%
Просрочено
4
13%
Работает
2
Разработчик 2
Оценка
(140)
Проекты
205
80%
Арбитраж
18
33% / 44%
Просрочено
10
5%
Работает
3
Разработчик 3
Оценка
(71)
Проекты
80
10%
Арбитраж
35
9% / 54%
Просрочено
6
8%
Работает
4
Разработчик 4
Оценка
(2)
Проекты
4
0%
Арбитраж
4
25% / 75%
Просрочено
1
25%
Свободен
5
Разработчик 5
Оценка
(9)
Проекты
21
5%
Арбитраж
1
0% / 0%
Просрочено
7
33%
Свободен
6
Разработчик 6
Оценка
(568)
Проекты
641
41%
Арбитраж
21
57% / 29%
Просрочено
47
7%
Работает
7
Разработчик 7
Оценка
(10)
Проекты
15
27%
Арбитраж
3
67% / 33%
Просрочено
0
Свободен
8
Разработчик 8
Оценка
(61)
Проекты
187
73%
Арбитраж
4
100% / 0%
Просрочено
1
1%
Свободен
9
Разработчик 9
Оценка
(125)
Проекты
159
42%
Арбитраж
20
60% / 20%
Просрочено
9
6%
Работает
Похожие заказы
Fibonacci EA 30 - 180 USD
This EA will utilize the Fibonacci indicator after a break of structure, there will be three trading points, the 23.6 , 76.4 and a hedge trade for the 23.6. More explanation will be made if you signify interest, my mql5 account has been funded and i am ready to get this started Right awaay
I need an MQL5 developer to create a trading bot for MT5 that executes trades based on order block closes. The bot should: Detect and analyze order blocks for trade entry. Automatically place trades with a risk-to-reward ratio of 1:2. Include customizable parameters and support backtesting. Experience with MQL5 and order block strategies is required
Life Creator 40 - 1000 USD
the topic of this robot is ,,life creator'' becouse when you have no idea what to do, this robot can help you and teach you how you can do it. The robot gonna creat you your own tactics which can help you in future. When you gonna see that it's really work you start to be happy and you gonna want to have more of this
I need assistance with configuring an MT4 setup so that every alert generated by an indicator is sent to a Discord channel. Requirements: Discord Webhook Integration: Implement functionality to send messages to a specified Discord channel using a Webhook URL. Capture Alerts from Indicator: Ensure that every alert triggered by a specific indicator (or multiple indicators) in MT4 is forwarded to the Discord channel
I need two trading view indicators to be on Mt4 .i want them to work the same way that they do on trading view if possible.i will send the indicators
Here are the paragraphs for the robot's settings to trade on various instruments: *US30 (Dow Jones)* - Symbol: US30 - Timeframe: H1 (1-hour chart) - Lot size: 0.1 - Take profit: 200 points - Stop loss: 150 points *Gold (XAUUSD)* - Symbol: XAUUSD - Timeframe: H4 (4-hour chart) - Lot size: 0.1 - Take profit: 1000 points - Stop loss: 800 points *Nas 100 (US Tech 100)* - Symbol: NQ100 - Timeframe: H1 (1-hour chart) - Lot
hi , i am looking for a Grid EA with some basic type of EA but fully functional and final one. so anyone who can do perfect EA should contact. plan is discussed as below. start and end time, and days of active deactive button should be added in dashboard or else like if we want to close EA for any future day or days in coming week so before time we should be able to set. when EA starts. it opens one buy or sell and
The EA is in below VPS Server: 176.57.188.42 User: administrator Password: Test123! Kindly access the vps to check out the EA, the name of the EA I'm referring to is called TOPGUN 2.0 The job is to replicate the same EA in the server and code a very similar one based on the exact functionality in that existing EA. if u can do it kindly reach out
Around 3,000 lines of code. This is NOT for a newbie or someone who will just try to figure it out and waste each other's time. Need a PRO who can work fast, smart, and follow the instructions exactly. NO creativity, NO improvising, NO doing what you feel is best. NO scatter brain working on 5 projects at once. Finish mine carefully and promptly then you take another job. If I say candle body it means the close price
hello everyone I need to create an ea that creates signals based on the indicator on trading view and transmits it directly to mt5, so that the signals are created on trading view and orders are opened in mt5

Информация о проекте

Бюджет
50+ USD
VAT (19%): 9.5 USD
Итого: 59.5 USD
Исполнителю
45 USD
Сроки выполнения
от 1 до 3 дн.