Page 1 of 1

How to get Bar number for a given date and time

Posted: Oct 01 2013
by arjfca
Hello

If I got in variables, a date and time. How could I get a bar number that correspond to it.
Is there a better way than to go bar by bar and comparing the date & time?

Martin

Re: How to get Bar number for a given date and time  [SOLVED]

Posted: Oct 01 2013
by TJ
Hello
If I got in variables, a date and time. How could I get a bar number that correspond to it.
Is there a better way than to go bar by bar and comparing the date & time?
Martin
There is no easy way to pinpoint a bar in history. Because in your chart the date/time are not continuous; you have missing dates and times between now and the bar you are looking for. eg. weekends, holidays. And you won't know which date/time are missing unless you go and check them bar by bar.

Re: How to get Bar number for a given date and time

Posted: Oct 02 2013
by Dru
Is there a better way than to go bar by bar and comparing the date & time?
symbol_date+symbol_time+binary search algorithm