Discussion of article "Finding seasonal patterns in the forex market using the CatBoost algorithm" - page 2

 
Maxim Dmitrievsky:

spread is taken into account in the custom tester, then the models are checked in the MT5 tester (see the 1st article in the series).

i.e. the logic is easily (relatively) transferred to MT5, almost automatically.

Yes, I have already looked at it. I understand that you take the average price (ask+bid)/2 for analysis. I saw it in your software and I think I will add it to my software. This spread spoils everything, spread noise on many pairs is larger than the average candle size. Here is the solution ). But on High and Low peaks it would be more spread to correct them as well ). Do you have corrections on all 4 points or only opening and closing? Or maybe it seems to me))). If you do not have it, you can try to add it. There will immediately smooth out the price series, and the variants that are inside the spread will fall out almost all at once.

 
I have because the spread closer to the point 0:00 everywhere rises in most of the variants there gets the search )))) you test in the tester and the spread is higher than the expectation )). I think with the introduction of this filter everything will change dramatically ))
 
Evgeniy Ilin:

Yes, I've already looked at it. I understand that you also take the average price (ask+bid)/2 for analysis. I saw it in your software, so I think I will add it to my software too. This spread spoils everything, spread noise on many pairs is larger than the average candle size. Here is the solution ). But on High and Low peaks it would be more spread to correct them as well ). Do you have corrections on all 4 points or only opening and closing? Or maybe it seems to me))). If you do not have it, you can try to add it. There will immediately smooth out the price series, and the variants that are inside the spread will fall out almost all at once

No, the opening prices. The spread is set at the stage of model training, i.e. trades below the spread are discarded.

 
Maxim Dmitrievsky:

no, the opening price. The spread is set at the stage of model training, i.e. trades below the spread are discarded

but you don't adjust the Open[] values. In general, the fact that I misunderstood all this gave me the right idea DDD. You can try to throw out spread noises by correcting Open[] Close[] High[] Low[] values using Spread at the same points. then you will get the price of say OpenX[i]=Open[i]+(Spread/2)*_Point. Exactly the middle between Ask and Bid ). This series is more reliable, because spread noise will be thrown out of the analysis.

 
Evgeniy Ilin:

but you don't adjust the Open[] values. In general, because I misunderstood all this, I had the right idea DDD. You can try to eliminate spread noises by correcting Open[] Close[] High[] Low[] values using Spread at the same points. then you will get the price of say OpenX[i]=Open[i]+(Spread/2)*_Point. Exactly the middle between Ask and Bid ). This series is more reliable, because spread noise will be thrown out of the analysis.

I have tried to correct in other ways, by moving clusters in the feature space, but that's another story ) Yes, you can do it that way.

 
Maxim Dmitrievsky:

logic is easily (relatively) transferred to MT5, almost on automatic.

can you publish an EA for this very model with timings?

 
Evgeni Gavrilovi:

can you publish an EA for this very model with timings?

The answer is the same as in the 2nd article, but in the terminal you need to add the limitation of opening trades by time, and all the

the same for days of the week and different combinations. Also in MT5 countdown of hours is shifted by 1 to the right, i.e. if in python the 4th hour, then in MT the 5th hour.

MqlDateTime hours;

void OnTick() {
//---
   if(!isNewBar()) return;
   TimeToStruct(TimeCurrent(), hours);
}

if(hours.hour == 5 && countOrders() == 0 && CheckMoneyForTrade(_Symbol,LotsOptimized(),ORDER_TYPE_BUY)) {
      if(sig < 0.5)
         OrderSend(Symbol(),OP_BUY,LotsOptimized(), Ask, 0, Bid-stoploss*_Point, Ask+takeprofit*_Point, NULL, OrderMagic);
      else if(sig > 0.5)
         OrderSend(Symbol(),OP_SELL,LotsOptimized(), Bid, 0, Ask+stoploss*_Point, Bid-takeprofit*_Point, NULL, OrderMagic);
      return;
   }
Документация по MQL5: Константы, перечисления и структуры / Состояние окружения / Информация об инструменте
Документация по MQL5: Константы, перечисления и структуры / Состояние окружения / Информация об инструменте
  • www.mql5.com
Информация об инструменте - Состояние окружения - Константы, перечисления и структуры - Справочник MQL5 - Справочник по языку алгоритмического/автоматического трейдинга для MetaTrader 5
 
Maxim Dmitrievsky:

The answer is the same as in the 2nd article, but in the terminal you need to add the limitation of opening trades by time, and that's it

the same for days of the week and different combinations. Also, in MT5 the hours countdown is shifted by 1 to the right, i.e. if in Python the 4th hour, then in MT the 5th one

thanks.

[Deleted]  
Bravo!  An amazing idea.  I take my hat off to you, you are so incredibly original and creative!!!!
 

Interesting and close topic.

It would be very curious to see the final equity of a standard MT5 tester on any of the FORTS instruments of your choice, obtained by applying this method.

As feedback, I am ready to post the equity of my seasonal algorithm on the selected instrument :)