Gamestudio Links
Zorro Links
Newest Posts
MT5 bridge not working on MT5 v. 5 build 4160
by EternallyCurious. 04/25/24 20:49
Data from CSV not parsed correctly
by EternallyCurious. 04/25/24 10:20
Trading Journey
by howardR. 04/24/24 20:04
M1 Oversampling
by Petra. 04/24/24 10:34
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
Scripts not found
by juergen_wue. 04/20/24 18:51
zorro 64bit command line support
by 7th_zorro. 04/20/24 10:06
StartWeek not working as it should
by jcl. 04/20/24 08:38
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
4 registered members (EternallyCurious, AndrewAMD, TipmyPip, Quad), 902 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Mega_Rod, EternallyCurious, howardR, 11honza11, ccorrea
19048 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 Online OP
Serious User
AndrewAMD  Online 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 (156 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,982
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,982
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 Online OP
Serious User
AndrewAMD  Online 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