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
the interval you specify is: current time - current time (current bar time) plus some number of seconds (i.e. some future time)
What do you want to get in a given interval? How will the price develop? "If I knew the price, I'd live in Sochi".
Nah. It's simpler than that.
I have the start of bar D1.
D1 + 86400 day minutes.
In those minutes I look for max/min and specify the time.
But Bars doesn't work at all on the first try, and I strongly suspect it occasionally lies. I'm trying to write a ToR for now, to cross-check :)
In any case, the problems with Bars turned out to be bigger than with Copy. In this thread, the man also seems to have a problem with Bars.
You don't need to take this question to servicedesk. What answer do you want to get?
OK, I won't.
PS To check that the function works.
Check (log) the start (t[0]+b) and end (t[0]) times of the range. You will get it right away.
OK, I won't.
PS to check if the function works.
I am telling you straight away that you will get 0 bars either way! There's nothing to check. If you don't understand why you will get 0 bars anyway, then ask the question here.
Question: how many bars did you want to get?
This is not enough. You should double-check the returned number of bars with another function.
I'm not saying it can't be enough. But you've got to start figuring things out somewhere. Otherwise, you'll be stuck in a bind every step of the way. )))
Check the values in the log or in the debugger and you will immediately know where to go next.
I tell you straight away that you will get 0 bars either way! There is nothing to check. If you don't understand why you will get 0 bars anyway, then ask the question here.
Counter question: how many bars did you want to get?
And I don't consistently get 0.
1st try - 0.
2nd try - value, but at the same time.
And it's on two adjacent bars, and the second value will consistently repeat, but the first will not.
And when running on minutes I got 6 in both cases, with b > 50000...
Anyway, okay. If all is well with the function, it's easier for me to discard it.
I'm not saying it can't be enough. But you've got to start figuring things out somewhere. Otherwise, you'll be stuck in a rut every step of the way. )))
Check the values in the log or in the debugger and you'll immediately know where to go from here.
This is not enough. You need to double-check the returned number of bars with another function.
If a function doesn't work, you should start looking for an error by checking the parameters passed to the function.
Stringo has already told you directly: "erroneous parameters are passed to the function", and you still can't understand it.
And I don't get a steady 0.
1st try - 0.
2nd try - value, but at the same time.
And running it on minutes would get 6 in both cases, with b > 50000...
Anyway, ok. If all is well with the function, it's easier for me to discard it.
You don't have to give up the function.
When you request data in the range"current time - current time plus some number of seconds", it means that you are requesting data from the future. The data does not yet exist at the time of the request.
If you were requesting data in the range "current time - current time minus some number of seconds", then you are requesting potentially existing data.
If a function does not work, you should start looking for an error by checking the parameters passed to the function.
Stringo has already told you directly: "erroneous parameters are passed to the function", and you still can't understand it.
OK, OK.
Got it, I'll correct myself, I'm off to learn.