Sultonov differential indicator - page 22

 
Ihor Herasko:

I have a question.

From the first post, it is clear how the indicator values are calculated. But it is one line. Why do most of the figures from the second page and further show two lines? What is the second line?

You are right to some extent, because after the constructive criticism of the participants that it had been done and that it was a "bicycle" in a new way, I have completely changed the logic of the indicator. Namely, I followed your procedure for bullish and bearish lines. The calculation point is considered bullish if the result of difference C0 - C1 >0 and belongs to the bullish line, otherwise it belongs to the bearish line. There is an automatic division of the one stream of the current price into 2 streams - bull and bear lines, which, depending on the relative strength of Bulls and Bears, began to pull ahead or lag behind. In this case, the strong Bulls "turn off", temporarily weaker Bears for the time of their market leadership and yield to Bears only when they, having accumulated strength during "hibernation", do not attack Bulls, sending them now into oblivion. According to the results of this battle on the 0-th bar of the chosen period N, the 0-th bar becomes the 1st bull or bear bar on history and the Bulls get an increment in strength if they are stronger than the Bears, or no increment if the Bulls are weaker than the Bears. These battles end when the last tick of the 0-bar arrives, which becomes the 1-bar. With the arrival of the first tick of the new 0-bar, the battles between the Bulls and the Bears start again from scratch, though taking into account the results of their fights on the previous bars of the chosen calculation period and the result of this fight will be known by the arrival of the last tick, then the calculation cycle repeats. With the arrival of a new zero bar we discard the values of the last history bar, which is a guarantee that, by definition, the indicator shouldn't redraw its history. This stage is lame so far and the indicator has become re-drawing. To check and confirm this unpleasant fact, I decided to look at the result of the indicator at N=1 which must become the first of its kind intra-bar indicator that doesn't have a history - an indispensable assistant for traders - scalpers, showing the power of Bulls and Bears in the "here and now" https://www.mql5.com/ru/charts/7608595/eurusd-m1-e-global-trade:


The increase in the indicator values according to the linear law indicates that, apparently, the RAM buffer is not being updated and reset properly.

График EURUSD, M1, 2017.09.12 13:21 UTC, E-Global Trade & Finance Group, Inc., MetaTrader 4, Real
График EURUSD, M1, 2017.09.12 13:21 UTC, E-Global Trade & Finance Group, Inc., MetaTrader 4, Real
  • www.mql5.com
Символ: EURUSD. Период графика: M1. Брокер: E-Global Trade & Finance Group, Inc.. Торговая платформа: MetaTrader 4. Режим торговли: Real. Дата: 2017.09.12 13:21 UTC.
 
Yousufkhodja Sultonov:

You are right in part, because after constructive criticism from the participants that it is a step too far and that it is a "bicycle" in a new way, I have completely changed the logic of the indicator's construction. Namely, I followed your procedure for bullish and bearish lines. The calculation point is considered bullish if the result of difference C0-C1 >0 and belongs to the bullish line, otherwise it belongs to the bearish line. There is an automatic division of the one stream of the current price into 2 streams - bull and bear lines, which, depending on the relative strength of Bulls and Bears, began to pull ahead or lag behind, in which the strong Bulls "turn off", temporarily weaker Bears for a time of their market leadership and yield to Bears only when they, having accumulated strength during the "sleep", do not hit the Bulls, sending them now into oblivion. According to the results of this battle on the 0-th bar of the chosen period N, the 0-th bar becomes the 1st bull or bear bar on history and the Bulls get an increment in strength if they are stronger than the Bears, or no increment if the Bulls are weaker than the Bears. These battles end when the last tick of the 0-bar arrives, which becomes the 1-bar. With the arrival of the first tick of the new 0-bar, the battles between the Bulls and the Bears begin again from a clean sheet, though taking into account the results of their fights on the previous bars of the chosen calculation period and the result of this fight will be known by the arrival of the last tick, then the calculation cycle repeats. With the arrival of a new zero bar we discard the values of the last history bar, which is a guarantee that, by definition, the indicator shouldn't redraw its history. This stage is lame so far and the indicator has become re-drawing. To check and confirm this unpleasant fact, I decided to look at the result of the indicator at N=1 that should become the first of its kind intra-bar indicator without the history - an indispensable assistant for traders - scalpers that shows the power of Bulls and Bears in the "here and now" https://www.mql5.com/ru/charts/7608351/eurusd-m1-e-global-trade:



So, already clearer. Now we need to find out what is Ц0 and Ц1? Intuitively, it is understood as closing prices of two adjacent bars. If so, we can rephrase the idea as follows: if the closing price rose, the obtained increase "drops" to the bulls' scales. Otherwise it falls on the scales of bears. You can not worry about price equality, because even if the difference will appear somewhere, it will be equal to 0 and will not make a difference.

Right?

 
Dmitry Fedoseev:

No, it's more likely that you haven't turned it on.

Well, for example, the first forecast - this one? It's not a fact that it was, it's drawn on history, and the indicator is a re-runner.

In terms of the indicator being repriced, I have repeatedly said that we must use the results of the last calculation and the calculation of the indicator lines, which are close, historically. You take words out of context of the general discussion of the principle of its work, only the word "re-run" means "fake", without paying attention to our statements about the truth of the verdict of the indicator on the 0-th bar. And you continue your persistence in the light of the fact that the programmer and I have already admitted an error in the code, which we will soon fix and the indicator will draw its readings on the principle "dipped as a stake", with no possibility of changing in time.
 
Ihor Herasko:

OK, that makes more sense. All that remains is to figure out what C0 and C1 are? Intuitively understood as closing prices of two adjacent bars. If so, then we can rephrase the idea as follows: if the closing price rose, the obtained increase "drops" to the bulls' scales. Otherwise it falls on the scales of bears. You can not worry about price equality, because even if the difference will appear somewhere, it will be equal to 0 and will not make a difference.

Right?

Price0 is the price at the current, zero bar - it changes when new ticks come and that is why the indicator redraws the zero bar incessantly. But, these differences are within the limits of the whole period N set in the indicator settings. All history bars within the N calculation period participate in giving the verdict on the 0-th bar. I have tried to recreate, in the above, the mechanism of appearance of values of the current Price on the Forex terminal and, apparently, I have hit "the mark", if participants accept my thinking algorithm as correct, and the indicator will show its consistency and objectivity helping traders earn at insignificant, unavoidable losses.

Торговые советники и собственные индикаторы - Алгоритмический трейдинг, торговые роботы - Справка по MetaTrader 5
Торговые советники и собственные индикаторы - Алгоритмический трейдинг, торговые роботы - Справка по MetaTrader 5
  • www.metatrader5.com
Среди программ для автоматического трейдинга можно выделить две большие категории: торговые роботы и индикаторы. Первые предназначены для...
 
Yousufkhodja Sultonov:
I have repeatedly said that we should be guided by the results of the last calculation and the calculation of nearby, in historical terms, lines of the indicator. You take the words out of the context of the general discussion of the principle of its work, only the word "re-routing" means "fake", without paying attention to our statements about the truth of the verdict of the indicator on the 0-th bar. And you continue your persistence in the light of the fact that the programmer and I have already admitted an error in the code, which we will soon fix and the indicator will draw its readings on the principle "dipped as a stake", with no possibility of changing in time.

Exactly - we should be guided by the last bar, and in that screenshot the signal is far away in history.

 
Yousufkhodja Sultonov:

Yes, you got it right, C0 is the price at the current, zero bar - it constantly changes when new ticks come and that's why indicator redraws the zero bar incessantly, and C1 is the price at the completed bar. But, these differences are within the limits of the whole period N set in the indicator settings. All history bars within the N calculation period participate in giving the verdict on the 0-th bar. I have tried to recreate, in the above, the mechanism of appearance of values of the current Price on the Forex terminal and, apparently, I have hit "the mark", if participants accept my thinking algorithm as correct, and the indicator will show its consistency and objectivity, helping traders earn at insignificant, unavoidable losses.


Then I don't yet understand the problems with overbidding. If the indicator only takes into account N bars of history, then what difference does it make at which point it was run? Either there is something else that I have not considered in this task or the indicator was written with a really stupid error which can easily be fixed. Generally speaking, under those conditions, the indicator is simple enough. At my leisure I will write my own version that does not re-draw.

 
Dmitry Fedoseev:

Exactly - we should be guided by the last bar, but on that screenshot the signal is far in the history.

From this "far" history the indicator forecasts are counted, because the "BAY" verdict was made exactly then and it was confirmed all the time after closing the next 0-bars. Now, is it clear? As soon as we fix the code, these conventions should disappear. What do you have to say or suggest concerning the logic of the indicator? Right now the Bulls are fighting for the market with varying success. It will soon become clear how their attempt will end.


 
Ihor Herasko:

Then I don't yet understand the problem with overshoot. If the indicator only takes into account N bars of history, then what difference does it make at which point it was run? Either there is something else that I have not considered in my task, or the indicator was written with a really stupid error, which is easy to correct. Generally speaking, under those conditions, the indicator is simple enough. I will at some point write my version that will not be re-drawn.

Yes, the error is evident - apparently, the buffer of memory is not refreshed and reset after the next tick. The programmer is very busy at the moment, it will be fixed soon. Yes, please write your variant and send it to me. You can add it to simple Expert Advisor to test it on the history.
 
Yousufkhodja Sultonov:
From this "distant" history the indicator predictions are counted, because, the verdict "BAY" was made exactly then and all the time confirmed after the closing of the next 0-bars. Now, is it clear? As soon as we fix the code, these conventions will disappear.
You have to correct the calculation. Not the indicator. There's something wrong with your calculation. It's not an error in the indicator. The report point shifts when you open a new bar. The amounts change accordingly. You are saying that we should not pay attention to this and calculate the amount only for the zero bar, while all the previous ones have already been drawn. But changing the timeframe and going back will show a completely different picture - the line will be recalculated from the new reference point.
Don't blame your mistake on me, please.
 
Yousufkhodja Sultonov:
Yes, the error is obvious - apparently the RAM buffer is not being updated and reset after the next tick arrives. The programmer is very busy at the moment, it will be fixed soon. Yes, please write your variant and send it to me. You may add it to a simple Expert Advisor to test it on history.
I won't fix it until you revise your approach to calculation.