WimParticipant
Junior
I am at my first step in programming a screener and already puzzled by some confusing results. I am doing some coding and testing on a saturday for an exchange that closed friday. So I would think that Close[0] would give the same price as the standard column “Last” in the screener results window. But no. “Last” is showing the closing price of last friday (as expected), but Close[0] is giving the closing price of thursday when in Daily and Friday one whole week ago when in Weekly. Close[1] is then of course giving the price of 2 days (in Daily) and 2 weeks (in Weekly) ago.
I tested this with this “exercise” part of code, where I exchanged the display part of the screener command for Close[1] and Gain and stuff.
// sample screener code - pogramming exercise
Gain = (Close[0] - Close[1])/Close[1]*100
SCREENER [Gain > 0](Close[0])
Probably a foolish beginner mistake, but I cannot find a formal explanation in the manual. Thanks for your “verdict”, Wim
Do you have end-of-day data?
WimParticipant
Junior
Yip. end of day. That’s why I am testing on Saturday.
On my PRT platform (end-of-day) data are correctly reported, both on Daily and Weekly TF’s.
WimParticipant
Junior
Your Daily/Adidas example looks OK. “Last” and “Crite.” (being Close[0]) are both 215.90.
But your Weekly/Muench example shows different values for “Last” and “Crite.” (being Close[0]), 208.50 resp. 206.4. The latter value being the close of the week before!
I guess it has to do with the availability of end of day data when using a free subscription. In Daily-mode the Friday-close is available already on Saturday (the next day). In Weekly-mode the Week-close is probably available on Monday (the next week). Will test that Monday morning. How about that idea? Bizar, however, that the column “Last” in ProScreener shows the correct Friday-close as well as the correct Week-close.
Thanks for testing on your side!
End of day is “end of week” for a weekly timeframe.