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

[amibroker] Identifying yesterday's closing price in intraday strategy



PureBytes Links

Trading Reference Links

Dear all,

I'm having trouble with identifying yesterday's closing price in my 
intraday strategy. I'm doing it like this:

Cl = ValueWhen(TimeNum()==155900.00, C, 1);

but the problem is that for some stocks/days 15:59 bar is not present 
and then the last day with 15:59 bar gets referenced.

Daychange = Day() != Ref(Day(), -1); 
Cl = ValueWhen(Daychange, Ref(C,-1), 1);

doesn't fit either because it is influenced by afterhours trading.

Any ideas?


Post AmiQuote-related messages ONLY to: amiquote@xxxxxxxxxxxxxxx 
(Web page: http://groups.yahoo.com/group/amiquote/messages/)

Check group FAQ at: http://groups.yahoo.com/group/amibroker/files/groupfaq.html 

Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/