Hello,
I have an issue working with timeframes.
I use a 1 hour timeFrame database and I want to compute misc parameters on daily timeframe based on previous day close.
Here is a sample code:
TimeFrameSet( inDaily );
CloseDaily = C;
TimeFrameRestore( );
AddColumn (TimeFrameExpand(CloseDaily,inDaily),"CloseDaily");
AddColumn (Close,"C");
Filter = 1;
The issue is that Close seems to be delayed by 1 day (minus 1 bar).
Here is what I obtain when I run an exploration on daily DB and on 1hour DB
Daily DB
1 hour DB
In the example above, I would like to have
Date/Time CloseDaily expected CloseDaily Actual
2022-08-26 15:30:00 34.97 36.96
2022-08-26 16:00:00 34.97 36.96
2022-08-26 16:00:00 34.97 36.96
… … …
2022-08-26 16:00:00 34.97 36.96
2022-08-26 21:00:00 34.97 34.97
How can I get correct result, ie, dailyClose expanded with the Close of the current day for all the previous hours of the day ?
Is this behavior due to US opening hours is not a multiple of Hours ?
Thanks,
Benoit