You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
I would like to ask a follow-up question...
There are pairs on which the EA does not optimize in any way, not even the first results appear. USDCHF, for example.
What may it be connected with?
Well, here we go again.
Once again for the twenty-sixth time.
There are no identical instruments in terms of price movement, there are similar ones.
We will not try to guess or conjure over the charts where to enter and when to do it.
That's why if there are no results, or only poor results, we should change the ranges and optimization periods, and you can also play with the SL and trailing levels. For some symbols I decreased the period up to three or even two weeks, I tried to increase SL for Yen crosses. In general, I try to find the best values which provide good results during optimization. As the result I consider relatively correct the parameters that give 6-8 thousand profitable combinations in 10 thousand runs during optimization with genetics. Then according to the law of large numbers probability of profit is twice as high as probability of loss, which means that optimization is just a formality and profits will exceed losses at least twice in case of significant number of weeks. Realistically more.
So, share how you are testing and what the results are. This is not easy in one week.
My balance for the week is +$690 and equity.... Equity's a little over +$750, eh, it was close to $1000 this afternoon. Almost all the positions have closed.
About the error. It is here in the startM1() function. Because of it there was a difference in first trades on the tester and demo.
//+------------------------------------------------------------------+
void startM1() {ticket = -1;RefreshRates();
if (total < HM_ALL) { BuSll (0,1,772012000); cmmnt();
if( !(DayOfWeek( ) == 1 && Hour( ) <2) && !(DayOfWeek( ) == 5 && Hour( ) >=18))
{if (Trd_Up_X && VSR() > 0 && bu<HM_Up_X&&Flq) {
if (MOS( 0, lots, sl, tp, WindowExpertName(), mn)==1) {Flq=false;}} // replace by >=
if (Trd_Dn_Y && VSR() < 0 && sll<HM_Dn_Y&&Flq) {
if (MOS( 1, lots, sl, tp, WindowExpertName(), mn)==1) {Flq=false;}} // replace with >=
}}
//+------------------------------------------------------------------+
The error is not critical, because of it the prohibition on opening of one more deal on one bar did not work.
I will fix it in new versions, but for now you can do it manually.
SHooter777ру: Советник понравился. После сегодняшнего слива демки оптимизацию делаю под 200$ (MiniForex). В принципе почти не отличается от 2000$. в оптимизационных сетах стоплоссы ставлю 50 с шагом 10, но все равно лучшие профиты со стоплоссами от 500 получаются. Уже в конечных сетах подбираю приемлемые в пределах 50-200 вручную. Влияет ли шаг и стоп в сетах на торговлю? (По наблюдениям не заметил). Еще вопрос: Можно ли оптимизировать под MicroForex (мин. лот 0,01)? Торгую на Pro Finance Group Inc платформа PFG FX Trader 4 (поддерживает MQL4). К сожалению на МикроФорексе нет демки.
Has anyone tried the EA in real life? Is it much different from the demo?
The picture shows trading in the demo this week with SHooter777r sets .Having +800 in trading balance I decided to use another EA on 3 pairs and ... greed killed the greed - available funds dropped below 100 and of course counter-positions were not opened, so my account almost went broke.
Good luck trading to everyone!
I downloaded the EA and was convinced again that to read someone else's year quickly, you need a more professional knowledge of the mql language, to write your own code, knowledge and experience is a minimum. The authors, if you post the code, write comments in it and divide the entire code into blocks.
This can be an interesting Expert Advisor, I might have recommended something from my own experience, but I don't want to delve into the raw code. Time is precious.
Something about the latest version doesn't work.
The optimiser doesn't even open a single trade at the first stage.
The tester with parameters optimised for the previous EA works the same way.
I'm sorry! I spent half an hour writing the instructions, but this glitchy forum not only glosses over the letters, it also lost all the text.
I'm going to write it in wordpress and paste it here. Wait a bit.
The new version of L9 contains a number of minor, but I think necessary, additions and changes.
First: the FLG() function has been added - it is responsible for two things
//+------------------------------------------------------------------+
bool FLG (int cs )
{ int AE = AccountEquity( ) ;
switch(cs)
{case 0: if((DayOfWeek( ) == 5 && Hour( ) >=22) || (TrBlnc && (AE > UBlnc))
return (true);else return (false);
case 1: string dttm = StringConcatenate (Year(),".",Month(),".",Day());
datetime smtm=StrToTime(dttm);
bool Gp;
int shft = iBarShift(NULL,0,smtm);
double iOpn = iOpen (NULL,0,shft); double iCls = iClose (NULL,0,shft+1);
double dOC = MathAbs ((iOpn - iCls)/(Point*10)) ;
if (dOC>20) Gp = true ; Print (Gp);
string var1=TimeToStr(smtm,TIME_DATE|TIME_SECONDS);
if((TrBlnc && ((AE > UBlnc)||(AE < DBlnc)) || (!Flq)
|| ((DayOfWeek( ) == 1 && Hour( ) <2) || (DayOfWeek( ) == 5 && Hour( ) >=18))
|| ((DayOfWeek( ) == 1 && Hour( ) <14) && Gp))
return (false);else return (true);
}
}
//+------------------------------------------------------------------+
a) FLG( 0 ) - forced closing of open positions at specified conditions.
b) FLG( 1 ) - prohibits opening of positions at specified conditions.
Here you can insert any additional conditions and do not "overload" void startM1() function and other places.
I selected end of week for forced closing if((DayOfWeek( ) == 5 && Hour( ) >= 22) and increasing Equity to some size
and prohibit opening at gep over a certain value if(dOC>20) Gp = true ; and if Equity increases to if((TrBlnc && ((AE > UBlnc)
or decreases to ||(AE < DBlnc))
So if you are testing or optimising, ensure that the Equity is within the range set in the parameters
bool TrBlnc = true; int StrtBlnc = 3000; int DBlnc = 1500; int UBlnc = 4000;
or add to int init() line if ( IsOptimization( ) ) TrBlnc = false;//if ( IsTesting() ) TrBlnc = false;
The following is not a change but rather a more substantial addition and refers to Delta_G12 now it is not delta AO but function G12(),
which, depending on its parameter extern int Indctr; uses either the former AO if Indctr = 1
or if Indctr = 2 any other function or indicator ( I use my own, TSM attached), if int Indctr = 0 then signals are summed from both indicators &&
//+FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF+
double G12() {switch(Indctr)
{case 0:
iCusAO_1 = iAO(NULL, 240, 1); iCusAO_2 = iAO(NULL, 240, 2);
iCusTSM_1 = iCusTSM (24, 1); iCusTSM_2 = iCusTSM (24, 2);
Dlt_AO12 = iCusAO_1 -iCusAO_2; Dlt_TSM12 = iCusTSM_1-iCusTSM_2;
if ( Dlt_AO12>=0 && Dlt_TSM12 <=0) return (0);
if ( Dlt_AO12<=0 && Dlt_TSM12 >=0) return (0);
return(Dlt_AO12);
case 1:
iCusAO_1 = iAO(NULL, 240, 1); iCusAO_2 = iAO(NULL, 240, 2);
Dlt_AO12 = iCusAO_1 -iCusAO_2; return(Dlt_AO12);
case 2:
iCusTSM_1 = iCusTSM (24, 1); iCusTSM_2 = iCusTSM (24, 2);
Dlt_AO12 = iCusTSM_1-iCusTSM_2; return(Dlt_AO12);}}
//+--------------------------------------------------------------------------------------+
double iCusTSM (int pr, int shft)
{ return (iCustom(NULL, 240, "iCus_N7S_TSM_forExp",pr,1,shft)); }
//+--------------------------------------------------------------------------------------+