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
Convert Yahoo Australia stock data to .t6 problem #486801
10/12/22 02:12
10/12/22 02:12
Joined: Mar 2017
Posts: 21
J
jyd Offline OP
Newbie
jyd  Offline OP
Newbie
J

Joined: Mar 2017
Posts: 21
Hi,

Does anyone have experience in converting australia stock csv from Yahoo finance to Zorro .t6 format? I am using the following code, which works but the resulting .t6 file is not loaded by Zorro.

int recordCount = dataParse(1, "%Y-%m-%d,f3,f1,f2,f4,f5,f6", "A2M.AX.csv");
if (recordCount) dataSave(1, "A2M.t6");

The csv can be download from: https://finance.yahoo.com/quote/A2M.AX/history?p=A2M.AX
The first few lines of the csv are as below
Date,Open,High,Low,Close,Adj Close,Volume
2015-03-31,0.555000,0.595000,0.530000,0.565000,0.565000,4816294
2015-04-01,0.575000,0.580000,0.555000,0.565000,0.565000,4376660
2015-04-02,0.560000,0.565000,0.535000,0.555000,0.555000,2779640
2015-04-07,0.545000,0.550000,0.540000,0.545000,0.545000,392179
2015-04-08,0.545000,0.545000,0.530000,0.540000,0.540000,668446
2015-04-09,0.540000,0.540000,0.532000,0.535000,0.535000,706846
2015-04-10,0.530000,0.535000,0.530000,0.535000,0.535000,175104
....

When I open the A2M.t6 file Zorro throw following errors:
History A2M.t6
Warning 035: A2M ticks overlap on 2015-04-01 00:00:00
Warning 035: A2M ticks overlap on 2015-04-02 00:00:00
Warning 035: A2M ticks overlap on 2015-04-07 00:00:00
Warning 035: A2M ticks overlap on 2015-04-08 00:00:00
A2M 1910 ticks read
Error 030: Wrong date range 2015-03-31 00:00:00 - 2015-03-31 00:00:00

However, if I use ZHistoryEditor to open the .t6 file, then I can view the file without any issue. If I re-save the file using ZHistoryEditor, then Zorro can load it correctly. So I guess I need to do some data clearance before converting it to the .t6 format? But I don't know what I need to do to clean the data. Thanks in advance if anyone can show me some hints, tips or instructions on this subject.

Re: Convert Yahoo Australia stock data to .t6 problem [Re: jyd] #486805
10/12/22 13:14
10/12/22 13:14
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Most likely, the data is in reverse order. Call dataSort(1) after dataParse.

https://zorro-project.com/manual/en/data.htm

Re: Convert Yahoo Australia stock data to .t6 problem [Re: jyd] #486813
10/13/22 13:20
10/13/22 13:20
Joined: Mar 2017
Posts: 21
J
jyd Offline OP
Newbie
jyd  Offline OP
Newbie
J

Joined: Mar 2017
Posts: 21
Thanks Andrew, you are right. data downloaded from yahoo is in reverse order, after that is corrected, it works. By the way, is there any function we can call to also fix the data outlier problem?

Re: Convert Yahoo Australia stock data to .t6 problem [Re: jyd] #486814
10/14/22 02:20
10/14/22 02:20
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
What outlier problem? Either the market was truly volatile, or you have bad data. I think you can figure out which is the case.

Re: Convert Yahoo Australia stock data to .t6 problem [Re: jyd] #486823
10/16/22 23:27
10/16/22 23:27
Joined: Mar 2017
Posts: 21
J
jyd Offline OP
Newbie
jyd  Offline OP
Newbie
J

Joined: Mar 2017
Posts: 21
ok, thanks for the tip


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