Gamestudio Links
Zorro Links
Newest Posts
Using Option Chains at 1 Minute Intervals
by pieran. 05/12/21 15:08
Experience with Dukascopy plugin
by Hajoha. 05/12/21 14:58
System with more take profit
by tomna1993. 05/12/21 13:55
Backtest accuracy
by tomna1993. 05/12/21 13:29
How to: plot a frequency spectrum in bars?
by Sempervirens. 05/12/21 12:04
Test one asset with more bar period in one run
by AndrewAMD. 05/12/21 10:12
EXANTE broker
by madpower2000. 05/11/21 17:02
No Trades when Backtesting Period is longer
by TimmiHendrix. 05/11/21 15:47
AUM Magazine
Latest Screens
Hecknex World
Scheherazade's Journey
Paradox Vector
The Space Between
Who's Online Now
9 registered members (pieran, Hajoha, Sempervirens, AndrewAMD, tomna1993, 3run, onoff, JeyKey II, 1 invisible), 474 guests, and 8 spiders.
Key: Admin, Global Mod, Mod
Newest Members
ShadowAx, TimmiHendrix, contactmmfx, msupl7, Robert_
18644 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Zorro - import diff time zones csv #482554
02/23/21 15:09
02/23/21 15:09
Joined: Aug 2020
Posts: 59
London
Neb Offline OP
Junior Member
Neb  Offline OP
Junior Member

Joined: Aug 2020
Posts: 59
London

Hi all,

If I have csv price history, which is not UTC time zone, but Chicago or Australia server, does Zorro have posibility to convert it, during import ?

Thanks,

Neb

Re: Zorro - import diff time zones csv [Re: Neb] #482555
02/23/21 17:11
02/23/21 17:11
Joined: May 2015
Posts: 379
Czech Republic
G
Grat Offline
Senior Member
Grat  Offline
Senior Member
G

Joined: May 2015
Posts: 379
Czech Republic
I had also this problem. My solution:

import CSV into Python/Pandas

convert timestamp to UTC/GMT

save with new Timezone

https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DatetimeIndex.tz_convert.html
Code
df.index = df.index.tz_localize('GMT')
df.index = df.index.tz_convert('America/New_York')

Last edited by Grat; 02/23/21 17:13.
Re: Zorro - import diff time zones csv [Re: Neb] #482556
02/23/21 17:52
02/23/21 17:52
Joined: Feb 2017
Posts: 1,255
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,255
Chicago
What you do is this:

1) Import the CSV to a dataset as you normally would, knowing that the timestamps are in the given timezone.
2) Modify the dataset using dataset functions and time functions, and the Now variable. Detect daylight savings with dst().
https://manual.zorro-project.com/data.htm
https://manual.zorro-project.com/month
https://zorro-project.com/manual/en/date.htm
3) Save your dataset to a t6 file with dataSave.

Re: Zorro - import diff time zones csv [Re: Neb] #482572
02/28/21 12:23
02/28/21 12:23
Joined: Aug 2020
Posts: 59
London
Neb Offline OP
Junior Member
Neb  Offline OP
Junior Member

Joined: Aug 2020
Posts: 59
London
Hi Grat, AndrewAMD,


Thank you both !

Neb


Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1