Author's - page 7

 

Probably didn't catch the idea well (from the code), as I'm not well versed in MQL5 syntax:

CopyBuffer(handle_sampler,0,bars_future,1,sigbuy); // получаем результат паттерна для покупки
CopyBuffer(handle_sampler,1,bars_future,1,sigsell); // получаем результат паттерна для продажи
Especially when it comes to indicators and their buffers. Can you rewrite the logic without these contrivances?
Документация по MQL5: Основы языка / Синтаксис
Документация по MQL5: Основы языка / Синтаксис
  • www.mql5.com
Основы языка / Синтаксис - Документация по MQL5
 
hrenfx:

Maybe I don't get the idea (from the code) as I don't know much about MQL5 syntax:

Especially when it comes to indicators and their buffers. Can you rewrite the logic without these contrivances?

It would be difficult without it, I have put this indicator in the database before. I have modified it a bit since then, but I think the meaning will be clear.

There are several ways to get signals and different settings, in the Expert Advisor settings are also present, this section ----- teacher parameters (sampler) -----.

 
I see, thank you. It turns out it's not the idea I had in mind at all.
 
hrenfx:
I understand now, thank you. It turns out I had a completely different idea.

Which other one? It might be enough to change the settings in the settings. The settings are very flexible.

Roughly speaking, this is an attempt to teach the Expert Advisor to trade like in the picture, where the indicator is.

I think this is what we were talking about.

How do you imagine a pattern belongs to a certain class? If you have a concrete suggestion, I will do it without indicator.

 

In my view there is no learning as such. There is just one array Patterns[index], the elements of which are incremented by one each time the index of a new bar changes value. Forgetfulness on each bar is also counted for the whole array.

As the result we get some set of the most frequent patterns.

Array PatternsNorm[] - normalize Patterns[] (average (elements > MinPorog) to zero, RMS = 1).

Then on the signal threshold PatternsNorm[index] performs trading actions.

 
her.human:

I see.

COM distributes the patterns according to its own characteristics. How to interpret them afterwards is still unclear to me.

Even after we have calculated all of the patterns on the history it is not clear what to do with them. If the current pattern on the history shows in most cases to buy - buy or sell.

I made an Expert Advisor (in the trailer).

What the Expert Advisor does:

- Memorizes all current patterns, which are made up of 10 different binary signals (you can choose from 17 variants so far),

Altogether we get 2^10=1024 different combinations of signals, buy and sell signals for each pattern are added up separately,

- Old patterns are gradually forgotten as new ones arrive (forgetting is regulated in the settings),

- We calculate the ratio of signals for each pattern, the type of which is outweighed (buy or sell), the signal is formed in the range from -1 to +1,

- Then we make a decision to enter, exit or reverse,

(here I do not know how to do it better, may be you can advise me how to do it better),

In general counts patterns in a direct way without GA and generalizations COM.

You can add variants of signals, the number of signals at the input (to increase the size of the input vector), or even input the outputs from COM.

Who is not lazy to try, may have thoughts on improvement.

I will not draw beautiful pictures, try it yourself).


Thanks Mr. Human.

And where do the "long" and "short" signals come from, did you write them in the code yourself?

 
her.human:
Can you elaborate on how you managed to identify 35/40/25%? And what can it give you for trading in the future?

But, it's not even about the numbers - there has to be a filter by market condition (working pair), so as not to teach NS to search for a trend pattern on a SB or flat section. Or don't trade on SB. It is also possible to identify the state by NS - like Ivan's Kohonen.

It goes something like this. All IMHO.

 
hrenfx:

In my view there is no learning as such. There is just one array Patterns[index], the elements of which are incremented by one each time the index of a new bar changes value. Forgetfulness on each bar is also counted for the whole array.

As the result we get some set of the most frequent patterns.

Array PatternsNorm[] - normalize Patterns[] (average (elements > MinPorog) to zero, RMS = 1).

Then on the signal threshold PatternsNorm[index] performs trading actions.

It looks like you haven't figured out the Expert Advisor, this is exactly what it does.
 

Yeah, didn't figure it out. I don't understand the idea then, though:

her.human:

It would be difficult without it, this indicator was posted earlier in the base. I've modified it a bit since then, but I think you'll get the idea.

I think it is very easy to write a syndicatorless Expert Advisor according to my description. And the approach is a bit different - there is no arr_buy and arr_sell.
 
hrenfx:

Yeah, didn't figure it out. I don't understand the idea then, though:

It seems to me that according to my description it is very easy to write an EA without indicators. And the approach is a bit different - no arr_buy and arr_sell.

Let's say we find the mostfrequent pattern, what does that pattern say? What should we do next, buy or sell?

Without dividing into buy and sell it is impossible to calculate the total number of patterns and therefore the average number of patterns.

The indicator only simplifies the code, allows visual control and enhances its capabilities, it does not do anything unnecessary.

You suggest only one way of interpreting the patterns, the indicator gives me several ways plus additional settings.

I don't like indicators myself, you can transfer indicator calculations to an EA, but then there will be problems with visual control.

Документация по MQL5: Основы языка / Функции / Функции обработки событий
Документация по MQL5: Основы языка / Функции / Функции обработки событий
  • www.mql5.com
Основы языка / Функции / Функции обработки событий - Документация по MQL5