Hedging EA

MQL4 Uzman Danışmanlar

İş tamamlandı

Tamamlanma süresi: 7 gün
Müşteri tarafından geri bildirim
Tuoitrecuoi once again amazes me by promptness of product and willingness to sit via Team Viewer for support and immediate changes. Tuoitrecuoi is the best programmer on MQL5.com

İş Gereklilikleri

Note: Do not be intimidated by lengthy EA explanation below. It is very simple in nature. I also attach an EA where lot of the concepts are already finished.

 

Idea behind EA:

The Hedging EA sole purpose is not to make money, but to automatically hedge against positions that I do not want to close out. The idea is to protect balance and equity and free up some margin. In the event that a trade becomes too far in the negative, I would close out the primary trade, which will automatically close the hedge order. The end result would be to minimized loss against those positions that venture off too far into the negative.

Repeater should work on all Symbols and charts:

Inputs Should Include:

BrokerIsECN = Yes/No

Wait For New Orders = Yes/No (This means when EA is applied to chart, to apply rules based on existing order or start with new orders).

Hedge at Amount = This will be a figure in dollars ($). This is where the EA will place a hedge trade. For example, if I enter in “20”, then EA will place a hedging trade at -$20

Time Between Open Orders in Minutes = Primary orders will have its own timer. Order 1 will work off a different timer then order 2. So if this option is set at “5”, and order 1 hedge is placed…….then order 2 will not have to wait 5 minutes but could place order immediately if conditions are correct. Same goes for closing the orders.

Take Profit in $= This option will give me the ability to take profit in the hedge trade. However, after take profit, order will wait “Time Between Open Orders in Minutes” option before reentering the market if the Hedging conditions still exist. If conditions still exist per “Hedge entry at amount”, another Hedge order will be entered in. 

Exit at Previous Entry (Default Edging Exit Position) = With this option, The hedging order will set a TP at its previous entry. In other words, if it hits this TP, there will be no profit.  Note: If a hedge order is closed with the “Take Profit In $” option, or is closed manually, then the next hedge order most likely will “not” have the same “Exit at Previous Entry” as previous order. The reason is, this order most likely will enter in a price different then the first hedging order.  The “Exit at Previous Entry” should be placed wherever the Hedge order enters the market. The Hedging can continue to reenter the market an unlimited amount of times as long as the primary order is opened, the previous hedge order is closed out, and other hedging conditions apply.

Use lot size of original order = this means hedging order will always match the size of the primary order

Fixed Lot Size = this means hedging order will always follow a specific size regardless of primary order size

 

Additional Options:

 

Exit at Previous Entry (Default Edging Exit Position) – Just wanted to post a note first that No option below will ever exit past this point of entry TP unless the “Active Hedge Minimum time” option below allows the trade to carry past this mark.

 

Active Hedge Minimum time = this is a timer for the minimum of how long the hedge order must stay opened before it can close. This will prevent the order from closing as soon as it opens due to pricing jumps. If the order is past the “Exit at Previous Entry “after the minutes expire, then the hedged position will close automatically at a loss.

 

Exit Hedge at Commission Rate = this option will set a TP at the cost of the hedging position.  “Active Hedge Minimum time” will still take priority over this rule. There are free tools that could assist with this option found https://www.mql5.com/en/market/product/4033 and https://www.mql5.com/en/market/product/3509

 

Hedging Exit in $ = The Idea for this option is to manually input a point where the EA will exit a trade in profit in $. The idea works much like a trailing stop rather than a TP option. It must cross a threshold before it can be activated. If the trade does not cross this threshold, then it will exit at “Exit at Previous Entry”.

Hedging Threshold in $ = This is the Threshold that the EA must cross before the “Hedging Exit in $” can be activated.

 

Example:

When Hedge order is activated, then activate “Exit at Previous Entry”. If trade meets/exceeds “Hedging Threshold in $”, then activate “Hedging Exit in $”. But exit must still play by “Active Hedge Minimum time” rules.

 

Notes:

When the original order is closed, it will automatically close the hedge order.

Performance Handling- It is extremely important that this EA be able to keep up with order volumes in volatile markets. At any given time, I may have 50+ orders opened. I don’t know if the EA’s are automatically effective when it comes to order processing, or if this feature needs to be built in with some kind of data-check. Do not worry about PC processing power if building in more code requires it. I do understand the volatile markets may cause slippage, however I am more worried about the EA confirming the trade has been executed, or that a hedge has actually been closed.

I have attached a very similar EA. The rules of the attached EA are almost identical, but only the attached EA repeats order rather than hedge them. Feel free to use this as a starting point.

If you have any question, please reach out to me. 

Yanıtlandı

1
Geliştirici 1
Derecelendirme
(88)
Projeler
138
25%
Arabuluculuk
33
33% / 45%
Süresi dolmuş
59
43%
Çalışıyor
2
Geliştirici 2
Derecelendirme
(362)
Projeler
506
40%
Arabuluculuk
147
18% / 72%
Süresi dolmuş
99
20%
Yüklendi
3
Geliştirici 3
Derecelendirme
(49)
Projeler
77
43%
Arabuluculuk
6
33% / 50%
Süresi dolmuş
22
29%
Serbest
4
Geliştirici 4
Derecelendirme
(647)
Projeler
1295
67%
Arabuluculuk
84
26% / 49%
Süresi dolmuş
338
26%
Serbest
Benzer siparişler
need developer to create personal EA for me, serious developer required. will work together on my robot. timeframe 1h, simple SMA and RSI levels, 1 h time frame, trading on limit orders only
Would you prefer to develop your own trading algorithm, or would you rather utilize a pre-existing bot?I want exactly the same settings as here, adding an option to choose the period of the Bollinger bands, otherwise I want each entry taken to be positioned as in the photo shareHello I made a note with the source code without any error I will also finish the note of what I want but I want something very similar just
This is based on a 180-day/30-day Exponential Moving Average when they cross. The entry will be when a counter-trend candle is exceeded by a trend candle and close to the 30-day moving average indicator line without touching it. Stop loss will be 2 pips below the prior counter trend candle. Trading long is when the price increases and the 30-day moving average crosses upward into the 180-day moving average. Trading
I would like to collaborate with a professional for this work, I have one indicator that is written in pine script (tradingview) language, I would like it to be converted to MQL5, that will further lead in making of trading bot according to conditions I will share with you the indicator file
I would like to collaborate with a professional for this work, I have one indicator that is written in pine script (tradingview) language, I would like it to be converted to MQL5, that will further lead in making of trading bot according to conditions I will share with you the indicator file
Hi Mark and Team, I would like to get help developing a trading robot that works this way 1. It must be a time-based robot, meaning it execute trades at a given time and hold till a specified time 2. I'd like to use a series of indicators (Support and resistance, RSI overbought/oversold, RSI Divergence, Trend Violated. 3. Instruments that meet these conditions gets ranked. This is done for both buy and sell
Copy reverse For MT5 Requirements: 1- Input parameter : Account Type= Master or Slave 2- Input parameter : Copy Speed in mille second for example equal 50 3- Input parameter : Master Account No. 4- Input parameter : Master Prefix , if master account pairs content of Prefix 5- Input parameter : Master Suffix , if master account pairs content of Suffix 6- Input parameter : Slave Prefix , if Slave account pairs content
Hello, i have this EA attached but its not working as it should on demo account. When using the strategy tester its different and good but on demo account its opens randomly orders any lot amount and not as it should be. You should check the EA and modify it so its working in demo account correctly as in the strategy tester. You can test it in EURUSD H1 for the last 4 months (default settings). Thank you
The EA is not working properly and I'm looking for a talented developer to fix all the bugs that's preventing it to work properly. I can provide a demo account for both of us to monitor while testing the finish product
i need an ea triggered as soon as parabolic sar indicator changes its signal to buy or sell and open same size orders with an option to add additional 0.01 or a diferent value to the initial lot on every next order no matter if it is buy or sell i need it to open orders in a (value) pips or price distance. using only a tp no stop loss. and close all orders on tp in money also i need a trailing stop in case price

Proje bilgisi

Bütçe
10 - 70 USD
Geliştirici için
9 - 63 USD
Son teslim tarihi
from 1 to 10 gün