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
Yes, by myself. In principle, I could post the code in MQL5 for the calculation.
Please tell me how to correctly compare Double ( == < > ). Does it need to be normalised? For example, there was such a function in MT4:
CompareDoubles(double number1,double number2)
{
if(NormalizeDouble(number1-number2,8)==0) return(true);
else return(false);
}
And in general, what is the approximate algorithm of NormalizeDouble() function?
Please tell me how to correctly compare Double ( == < > ). Does it need to be normalised? For example, in MT4 there was such a function:
CompareDoubles(double number1,double number2)
{
if(NormalizeDouble(number1-number2,8)==0) return(true);
else return(false);
}
Please tell me how to correctly compare Double ( == < > ). Does it need to be normalised? For example, there was such a function in MT4:
CompareDoubles(double number1,double number2)
{
if(NormalizeDouble(number1-number2,8)==0) return(true);
else return(false);
}
And in general, what is the approximate algorithm of NormalizeDouble() function?
It is known that at the beginning of the chart the history is incorrect, the question "why is it incorrect" does not arise.
Another question arises: how can we programmatically determine the boundary beyond which the incorrect history data follows?
The red vertical line shows the boundary.
It is known that at the beginning of the chart the history is incorrect, the question "why is it incorrect" does not arise.
Another question arises: how can we programmatically determine the boundary beyond which the incorrect history data follows?
The red vertical line shows the boundary.
Maybe one can try to determine somehow by the frequency of gaps? Count gaps for a certain period.
There are a lot of ways to get twisted. But I don't see any that are really reliable. Because there is no real criterion for judging the "authenticity" of the data of each individual bar.
All charts are based on minute bars. It could be calculated programmatically up to the date when the correct creation of an older required timeframe is possible. But there is a "however" here, too. However, the minute TFs are not correct to the whole history depth either:
I don't know, IMHO, we need a standard mechanism for identification of such limits, something like this
-returns the index of the last valid bar of the requested symbol of the required TF.
I don't know, IMHO, we need an in-house mechanism for defining such limits, something like
-returns the index of the last valid bar of the requested instrument of the required TF.
-returns the index of the last valid bar of the requested instrument of the required TF.
There are a lot of ways to get twisted. But I don't see any that are really reliable. Because there is no real criterion for judging the "authenticity" of the data of each individual bar.
All charts are based on minute bars. It could be calculated programmatically up to the date when the correct creation of an older required timeframe is possible. But there is a "however" here, too. However, the minute TFs are not correct to the full depth of history either:
I don't know, I think we need a special mechanism for defining such limits, something like
-returns the index of the last correct bar of the requested symbol of the required TF.