[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: date>date[1]



PureBytes Links

Trading Reference Links

I'm in California, using the regular sessions of
NASD. When time of the current tick is less than
the time of the last tick I have experienced the
first bar of the next day. Works flawlessly. I am
building intraday and daily  bars in arrays from
tick data and it is working flawlessly for months
now. If I was using a 24 hour day it would still
work, 00:00 is less then 23:59, even in Easy
Language!! I could use the 24 hour day from
anywhere, I'm assuming the day would start at
00:00 exchange time and I would only have to make
sure I was not using local time.

I had problems comparing the dates but
comparisons of times has presented no problem at
all, I recommend it.

Max

============================================

Max wrote:
>I had better results using time <time[1] to 
detect a day rollover

That will only work if you have single session 
data only, or if the
new trading day actually begins at midnight.  If 
you use 24-hour
data, or live in a time zone where the trading 
session contains
midnight (such as trading the Bund from Hawaii), 
you need to do
something else.


=====
"The race may not always go to the swift nor the battle to the strong, but it is the way to bet"