Hedging EA

MQL4 Esperti

Specifiche

Develop a MT4 hedging EA that will monitor, alert & response to the account's equity and the floating profit/loss of all open trades. 
There is a maximum of 40 open trades with 10 trades for the EURUSD (Group#1), 10 trades for the GBPUSD(Group#2), 10 trades USDCHF(Group#3) and 10 trades for the USDJPY(Group#4). Each trade will be identified by its magic numbers.   


All profit/loss mention below are in pips and NOT dollars. 

Every tick from MT4, we will monitor the account balance, equity, and floating profit/loss of each group separately.

Check all the open trades of Group#1, calculate balance, equity, profit/loss. Note that profit/loss will be calculated in pips and not dollars.
AccountBalance();
AccountEquity();
Loss (in pips) = convert to pips (AccountEquity() - AccountBalance());

Update the largest loss of 5 minutes of Profit/Loss for group #1
Update the largest loss of the previous 10 ticks of Profit/Loss for group #1
Update the current loss for the present tick of Profit/Loss for group#1


Part 1.
if Option 1 = true (ignore options 2)

Close all winning buy trades if the total of all winning buy trades > Buy_Total_winning_limit
Close all winning sell trades if the total of all winning sell trades > Sell_Total_winning_limit
Close all losing buy trades if the total of all losing buy trade > Buy_Total_losing_limit
Close all losing sell trades if the total of all losing sell trades > Sell_Total_losing_limit

Part 2.   
if Option 2 = true (ignore options 1)
Volume equal example - if there are 5 buy trades, then the volume equal will be 0.5 lot, if there are 7 sell trades, then the volume equal will be 0.7 lot. Each trade is counted as 0.1 lot. 

Open sell trades with volume equal to the total of all winning buy trades > Buy_Total_winning_limit
Open buy trades with volume equal to the total of all winning sell trades > Sell_Total_winning_limit
Open sell trades with volume equal to all losing buy trades > Buy_total_losing_limit
Open buy trades with volume equal to all losing sell trades > Sell_total_losing_limit

Exit sell trades when total of all winning buy trades > (Buy_Total_winning_limit - G_1_hysteresis_buy_constant) 
Exit buy trades when total of all winning sell trades > (Sell_Total_winning_limit - G_1_hysteresis_sell_constant) 
Exit sell trades when total of all losing buy trades > (Buy_total_losing_limit - G_1_hysteresis_buy_constant)

Exit buy trades when total of all losing sell trades > (Sell_total_losing_lmit - - G_1_hysteresis_sell_constant) 

 

#property link      ""
#property version   "1.00"
#property strict

input double BaseLots = 1;


input bool Option_1 = true;
//group1 symbol = EURUSD
input int Group1_Buy_Total_winning_limit = 3000; //300 pips for 5 digits broker
input int Group1_Sell_Total_winning_limit = 3000;//300 pips for 5 digits broker
input int Group1_Buy_Total_losing_limit = 3000;//300 pips for 5 digits broker
input int Group1_Sell_Total_losing_limit = 3000;//300 pips for 5 digits broker
//group2 symbol = GBPUSD
input int Group2_Buy_Total_winning_limit = 3000; //300 pips for 5 digits broker
input int Group2_Sell_Total_winning_limit = 3000;//300 pips for 5 digits broker
input int Group2_Buy_Total_losing_limit = 3000;//300 pips for 5 digits broker
input int Group2_Sell_Total_losing_limit = 3000;//300 pips for 5 digits broker
//group3 symbol = USDJPY
input int Group3_Buy_Total_winning_limit = 3000; //300 pips for 5 digits broker
input int Group3_Sell_Total_winning_limit = 3000;//300 pips for 5 digits broker
input int Group3_Buy_Total_losing_limit = 3000;//300 pips for 5 digits broker
input int Group3_Sell_Total_losing_limit = 3000;//300 pips for 5 digits broker
//group4 symbol = USDCHF
input int Group4_Buy_Total_winning_limit = 3000; //300 pips for 5 digits broker
input int Group4_Sell_Total_winning_limit = 3000;//300 pips for 5 digits broker
input int Group4_Buy_Total_losing_limit = 3000;//300 pips for 5 digits broker
input int Group4_Sell_Total_losing_limit = 3000;//300 pips for 5 digits broker

//group1 symbol = EURUSD
 int Group1_Buy_Total = 0; 
 int Group1_Sell_Total = 0;
 int Group1_Buy_Total = 0;
 int Group1_Sell_Total = 0;
//group2 symbol = GBPUSD
 int Group2_Buy_Total = 0; 
 int Group2_Sell_Total = 0;
 int Group2_Buy_Total = 0;
 int Group2_Sell_Total = 0;
//group3 symbol = USDJPY
 int Group3_Buy_Total = 0; 
 int Group3_Sell_Total = 0;
 int Group3_Buy_Total = 0;
 int Group3_Sell_Total = 0;
//group4 symbol = USDCHF
 int Group4_Buy_Total = 0; 
 int Group4_Sell_Total = 0;
 int Group4_Buy_Total = 0;
 int Group4_Sell_Total = 0;

int btwl = 0;
int stwl = 0;
int btll = 0;
int stll = 0;
input bool Option_2 = false;
input int G_1_hysteresis_buy_constant = 50;
input int G_1_hysteresis_sell_constant = 50;

int Slippage = 100;
//Magic numbers: 1 to 10 will be trading the EURUSD
int Group1_magic1 = 1;
int Group1_magic2 = 2;
int Group1_magic3 = 3;
int Group1_magic4 = 4;
int Group1_magic5 = 5;
int Group1_magic6 = 6;
int Group1_magic7 = 7;
int Group1_magic8 = 8;
int Group1_magic9 = 9;
int Group1_magic10 = 10;
//Magic numbers: 11 to 20 will be trading the GBPUSD
int Group2_magic1 = 11;
int Group2_magic2 = 12;
int Group2_magic3 = 13;
int Group2_magic4 = 14;
int Group2_magic5 = 15;
int Group2_magic6 = 16;
int Group2_magic7 = 17;
int Group2_magic8 = 18;
int Group2_magic9 = 19;
int Group2_magic10 = 20;
//Magic numbers: 21 to 30 will be trading the USDJPY 
int Group3_magic1 = 21;
int Group3_magic2 = 22;
int Group3_magic3 = 23;
int Group3_magic4 = 24;
int Group3_magic5 = 25;
int Group3_magic6 = 26;
int Group3_magic7 = 27;
int Group3_magic8 = 28;
int Group3_magic9 = 29;
int Group3_magic10 = 30;

//Magic numbers: 31 to 40 will be trading the USDCHF 
int Group4_magic1 = 31;
int Group4_magic2 = 32;
int Group4_magic3 = 33;
int Group4_magic4 = 34;
int Group4_magic5 = 35;
int Group4_magic6 = 36;
int Group4_magic7 = 37;
int Group4_magic8 = 38;
int Group4_magic9 = 39;
int Group4_magic10 = 40;

 

 

Con risposta

1
Sviluppatore 1
Valutazioni
(182)
Progetti
342
42%
Arbitraggio
118
12% / 73%
In ritardo
104
30%
Gratuito
2
Sviluppatore 2
Valutazioni
(54)
Progetti
164
43%
Arbitraggio
43
47% / 16%
In ritardo
58
35%
Gratuito
3
Sviluppatore 3
Valutazioni
(62)
Progetti
140
46%
Arbitraggio
19
42% / 16%
In ritardo
32
23%
Gratuito
Ordini simili
a coder is required to add an indicator to existing ea The new indicator will work as 1. option to combine with exiting indicator to open trade 2. it will be used as alternative BE point 3. It can also be used to close order or combine with other to close trade The second Job is telegram bot to get alert fr news trade and others Details when you apply i will test the ea work on live market and all bug is fixed before
Hello, I want to make an EA based on SMC and a developer that is familiar with the concept and full understanding of this. Must have done similar jobs before and be able show it. I only want to work with developer that has good track record and is precise. Further information will be handed when contact is made. Developers that has zero rating will not be considered. Listed price is a base point. The project can also
EA DEJA FABRIQUE ? MODIFIER QUELQUE LIGNE POUR LE RENDRE RENTABLE /////////////////////++++++++++++++++++++++++++++++++++ EA AVEC UN SYTEME SIMPLE ; SEULEMENT A MODIFIER %%%%%%%%%%%%%%%%%% SI PERSONNE SACHANT CODER CORRECTEMENT , CE TRAVAIL EST POUR TOI
Trade methodology based on Red and Green lines entering Overbought / Oversold zone. Using confluence of Higher time frame, Moving Average a trade can enter when there is a strong slope angle. Market Base Line is used to determine overall market sentiment. This is designed to be an established trend scalping strategy on lower time frames. To be used initially on demo then real account when settings have been fine
There are six conditions in total . source code from an existing expert will be provided to aid the completion of this job . - Install the following by the Panel (copy paste form my existing Expert ) 1. Pips Lost : number of pips lost ( monthly reset ) 2. Pips Gained : number of pips gained ( monthly reset ) 3. Have a black background to avoid the
:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: function (A) Add Transform combine the 4 Expert Advisors into just 1 Expert Advisor, maintaining the individuality of each one Leave in extern (false) or (true)
Description: I am seeking an experienced MQL5 developer to create a custom Expert Advisor (EA) for MetaTrader 5 based on a specific trend-following strategy. The strategy includes precise risk management, advanced trade management features, and additional risk management tools. The EA should be adaptable to any timeframe on which it is attached. Below are the detailed requirements and parameters for the EA: Strategy
I need an EA trading frequently (HFT or something like), and it sould have some features below: 1、Have a clear trading logic 2、Have a good backtest result 3、Have a demonstrated benefitable result in a live account trading 4、Can avoid the news time period or not sensitive to news
Tenho um EA mql4 que está com funcionalidades funcionando e outras com funcionalidades sem funcionar. Tenho um vídeo do EA funcionando como deve funcionar perfeitamente. O meu não consegue seguir o mesmo programa pois quando coloca os pontos de parada e retirada são bem diferentes. Não tenho pressa para tempo, só queria que conseguisse renovar o EA. O arquivo do grafico anexo é como ele se encontra agora. O certo é
New york session based strategy 9:30 open Price takes out buy side or sell side liquidity Usually using 15min high and lows 5m entry Price takes out that high/low and price must close strongly back into the zone Is price is above price we have a sell bias vis versa for buys Sl is at the high or low with option for “offset” for cushion Tp is usually the opposite High or low. Would like the option for set pips-points &

Informazioni sul progetto

Budget
45 USD
Per lo sviluppatore
40.5 - 40.5 USD
Scadenze
da 5 a 15 giorno(i)