Custom data bundles... the format ?

610 views
Skip to first unread message

flibbr

unread,
May 24, 2016, 9:43:45 AM5/24/16
to Zipline Python Opensource Backtester
Hi,

So i've downloaded zipline, and now I want to import and use a custom data set.

I can get the minute by minute OHLC & Volume . . .

But how do I store this.. in what kind of format... ? Documentation seems kind of weak/non existent around this.
I've had multiple looks on http://www.zipline.io/bundles.html#writing-a-new-bundle with not much luck.
The page says;

Data bundles exist to make it easy to use different data sources with zipline. To add a new bundle, one must implement an ingest function.


Cool, "ingest" function. Fine. But ingest what ? A CSV File ? A Json file ? I don't understand what it's mean to be ingesting in what kind of format.
The page goes on..

The ingest function is responsible for loading the data into memory and passing it to a set of writer objects provided by zipline to convert the data to zipline’s internal format. The ingest function may work by downloading data from a remote location like the quandl bundle or yahoo bundles or it may just load files that are already on the machine.


The site then goes on to describe the ingest function...  which is all pretty meaningless to me... 
Does anyone have any examples of using this ingest function to make custom bundles  to backtest against ?
 
Thanks in advance.

Zichao Li

unread,
Jun 22, 2016, 3:52:42 AM6/22/16
to Zipline Python Opensource Backtester

Same question here. Anyone has successfully done that? Could you please share some invaluable experience? Thanks!
在 2016年5月24日星期二 UTC+8下午9:43:45,flibbr写道:

Vishal Gandhi

unread,
Jul 29, 2016, 10:51:58 PM7/29/16
to Zipline Python Opensource Backtester
I am trying to do that, but looks like yahoo bundle that came with zipline installation is not working.  Looks like ingest function is not being called.  I need to fix this first.
In my case, it does download quantopian-quandl , but it doesn't do anything with yahoo or at-least doesn't show any message on the screen.  I've added following code to my extension.py file:

symbols = (
        'AMD',
        'AEG',
        'ARC',
)
from zipline.data.bundles import yahoo_equities, register
register('my_yahoo_bundle', yahoo_equities(symbols,'2016-07-21','2016-07-29'))

I see progress-bar for quantopian-quandl only.  No errors or warnings.  Any thoughts?

OriginGod Huang

unread,
Aug 2, 2016, 5:44:10 AM8/2/16
to Zipline Python Opensource Backtester
I'm working on loading local datasource too, walk a long way and failed...
I try to custom my data bundle to work around those problems, any one have an idea on that?

在 2016年7月30日星期六 UTC+8上午10:51:58,Vishal Gandhi写道:
Reply all
Reply to author
Forward
0 new messages