- ago
Is there a way to calculate end of day data from smaller time frames and use it as input for EOD based strategies?
0
859
Solved
8 Replies

Reply

Bookmark

Sort
- ago
#1
It's BarHistoryCompressor, you already know it:
https://www.wealth-lab.com/Discussion/Setting-up-a-multi-time-frame-strategy-and-IB-data-10-min-daily-7568
0
- ago
#2
My question should be more in the direction of whether I can generate EOD data from the smaler time frame and save it as such, for example to use as input for a strategy based on building blocks, to be sure to have identical data for all strategies.
0
- ago
#3
I see but it doesn't look like a valid reason to me. If the source is identical, the compressed data object is too. What makes you think it's needed?
0
Glitch8
 ( 11.27% )
- ago
#4
You could write a strategy to compress intraday data , and save it to a file in ASCII format. Then use an ASCII DataSet to consume your data.
1
Best Answer
- ago
#5
Thanks, that's worth a try.
0
- ago
#6
Still I don't understand the premise which duplicates the effort.
0
- ago
#7
This is possibly because I am not yet sufficiently familiar with the possibilities of WL7.
In the Execute method I get one event for every 10 minutes bar. To execute a daily strategy on this data I would have to use the timing of the 1st bar of the day for the close, for example, or the last bar of the previous day (for a close in the morning auction).
For the buy, in my case, I would have to use the close of the day (i.e. the close of the last 10 minutes bar) to calculate the buy limit for the coming day.
I see a lot of opportunities to make mistakes here, which are very difficult (for me) to find.
Maybe there is a way that WL7 works directly on the compressed day data and I don't have to do this conversion explicitly.
0
Cone8
 ( 4.92% )
- ago
#8
A few things to note:
1. There can be differences in the 4pm close and the Daily settled close - especially for NYSE stocks, which typically settle seconds to several minutes after the close. If you compress intraday data, you won't be working with Settled closes.

2. If you only need the close for the previous day, that's easy find in Strategy code.

3. If you need to create indicators with Daily data and don't care really about the settled close, it's a straightforward operation to compress to Daily and synchronize to the intraday chart for trading/graphing.

Just let us know exactly where you're having a problem and we'll give you a solution.
0

Reply

Bookmark

Sort