Lagged data when history file contains repeated time stamps

Posted By: JamesHH

Lagged data when history file contains repeated time stamps - 04/19/20 05:11

I am posting here because this looks like a potentially serious bug to me.

I was working with the timeseries for EURUSD_2015 in CSV format, which I obtained from ZHistoryEditor. These prices, especially the High and Low prices, do not always match what Zorro sees from the original EURUSD_2015.t6 file. In some cases Zorro is getting lagged values, and this only happens when a timestamp is repeated. For example:

In EURUSD_2015.csv, after reversing the order, we have

1 2015-01-02 03:45:00 1.21002 1.21002 1.20584 1.20593 30
2 2015-01-02 03:45:00 1.21002 1.21002 1.20584 1.20593 30
3 2015-01-02 03:46:00 1.20593 1.20625 1.20590 1.20625 131

But in EURUSD_2015.t6 when read from Zorro (I don't know how to read volume with free Zorro), we have lagged High and Low prices:

1 2015-01-02 03:46:00 1.20593 1.21002 1.20584 1.20625

Another example: From EURUSD_2015.csv we have

11 2015-01-02 03:52:00 1.20604 1.20610 1.20592 1.20593 60
12 2015-01-02 03:53:00 1.20593 1.20600 1.20585 1.20594 90
13 2015-01-02 03:53:00 1.20593 1.20600 1.20585 1.20594 90

while Zorro read the following from EURUSD_2015.t6 with a lagged High value:

7 2015-01-02 03:52:00 1.20604 1.20610 1.20592 1.20593
8 2015-01-02 03:53:00 1.20593 1.20610 1.20585 1.20594

There are several hundred such examples in EURUSD_2015.

I suppose it is conceivable that the error is in ZHistoryEditor. The correct timeseries depends on which one is to be trusted (between Zorro and ZHistoryEditor).

When I removed the duplicates from the CSV, and then recreated the history file (using a Zorro script) everything agrees.
Posted By: JamesHH

Re: Lagged data when history file contains repeated time stamps - 04/22/20 05:53

PS. Just reread my post and realized that this can easily be verified by starting from a CVS file with duplicate timestamps and then generating the t6.
Posted By: jcl

Re: Lagged data when history file contains repeated time stamps - 04/27/20 10:36

Is this a bug report for Zorro or for the ZHistory editor? If for Zorro, with which script you got wrong converted duplicates?
© 2024 lite-C Forums