Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by EternallyCurious. 04/18/24 10:45
StartWeek not working as it should
by Zheka. 04/18/24 10:11
folder management functions
by VoroneTZ. 04/17/24 06:52
lookback setting performance issue
by 7th_zorro. 04/16/24 03:08
zorro 64bit command line support
by 7th_zorro. 04/15/24 09:36
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:48
Zorro FIX plugin - Experimental
by flink. 04/14/24 07:46
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (SBGuy), 712 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
contract() - range of timestamps in [Test] mode #482183
01/07/21 18:35
01/07/21 18:35
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Offline OP
Serious User
AndrewAMD  Offline OP
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
jcl,

In [Test] mode, suppose you have an intraday t8 file, and there are four actively traded and unexpired futures contracts, say, for ES (E-Mini).

Every minute, some contracts will have a tick, and some will not. There is a varying number every time.

So when using BarPeriod=1, you call contractUpdate(). It only loads as many contracts as exist at the given timestamp rather than all actively traded contracts.

Why not allow the user to select a date range of ticks? Now I understand there can be duplicate contracts in a given date range, so maybe have it output an array of CONTRACT pointers, so that only the most recent unique contract can be selected in the set.

In other words, the most recent March 2021 ES tick would be picked up and not any prior one. Same for the most recent June 2021 ES tick.

The attached snapshot helps to illustrate the problem.

I do realize that one workaround is to fill the t8 file with many zero-volume ticks for all contracts, but that would make the t8 files larger.

[Linked Image]

Attached Files
Snap.PNG (155 downloads)
Re: contract() - range of timestamps in [Test] mode [Re: AndrewAMD] #482188
01/08/21 11:38
01/08/21 11:38
Joined: Jul 2000
Posts: 27,978
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,978
Frankfurt
A solution could be a contractUpdate mode that does not discard the old contracts, but just updates their prices. I'll put it on our list.

Re: contract() - range of timestamps in [Test] mode [Re: AndrewAMD] #482189
01/08/21 14:12
01/08/21 14:12
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Offline OP
Serious User
AndrewAMD  Offline OP
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Yes, that should work. Thanks!


Moderated by  Petra 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1