-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MAINT: make the data loading apis more consistent.
Changes BcolzDailyBarWriter to not be an abc, data is passed as an iterator of (sid, dataframe) pairs to the write method. Changes the AssetsDBWriter to be a single class which accepts an engine at construction time and has a `write` method for writing dataframes for the various tables. We no longer support writing the various other data types, callers should coerce their data into a dataframe themselves. See zipline.assets.synthetic for some helpers to do this. Adds many new fixtures and updates some existing fixtures to use the new ones: WithDefaultDateBounds A fixture that provides the suite a START_DATE and END_DATE. This is meant to make it easy for other fixtures to synchronize their date ranges without depending on eachother in strange ways. For example, WithBcolzMinuteBarReader and WithBcolzDailyBarReader by default should both have data for the same dates, so they may use depend on WithDefaultDates without forcing a dependency between them. WithTmpDir, WithInstanceTmpDir Provides the suite or individual test case a temporary directory. WithBcolzDailyBarReader Provides the suite a BcolzDailyBarReader which reads from bcolz data written to a temporary directory. The data will be read from dataframes and then converted to bcolz files with BcolzDailyBarWriter.write WithBcolzDailyBarReaderFromCSVs Provides the suite a BcolzDailyBarReader which reads from bcolz data written to a temporary directory. The data will be read from a collection of CSV files and then converted into the bcolz data through BcolzDailyBarWriter.write_csvs WithBcolzMinuteBarReader Provides the suite a BcolzMinuteBarReader which reads from bcolz data written to a temporary directory. The data will be read from dataframes and then converted to bcolz files with BcolzMinuteBarWriter.write WithAdjustmentReader Provides the suite a SQLiteAdjustmentReader which reads from an in memory sqlite database. The data will be read from dataframes and then converted into sqlite with SQLiteAdjustmentWriter.write WithDataPortal Provides each test case a DataPortal object with data from temporary resources.
- Loading branch information
Joe Jevnik
committed
Apr 16, 2016
1 parent
8c64cc8
commit bc0b117
Showing
68 changed files
with
5,108 additions
and
4,885 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -66,3 +66,5 @@ zipline.iml | |
|
||
# PyCharm custom settings | ||
.idea | ||
|
||
TAGS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
Development | ||
----------- | ||
|
||
:Release: 1.0.0 | ||
:Date: TBD | ||
|
||
.. warning:: | ||
This release is still under active development. All changes listed are | ||
subject to change at any time. | ||
|
||
|
||
Highlights | ||
~~~~~~~~~~ | ||
|
||
None | ||
|
||
Enhancements | ||
~~~~~~~~~~~~ | ||
|
||
* Made the data loading classes have more consistent interfaces. This includes | ||
the equity bar writers, adjustment writer, and asset db writer. The new | ||
interface is that the resource to be written to is passed at construction time | ||
and the data to write is provided later to the `write` method as a | ||
dataframe. This model allows us to pass these writer objects around as a | ||
resource for other classes and functions to consume (:issue:`1109`). | ||
|
||
Experimental Features | ||
~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
.. warning:: | ||
|
||
Experimental features are subject to change. | ||
|
||
None | ||
|
||
Bug Fixes | ||
~~~~~~~~~ | ||
|
||
None | ||
|
||
Performance | ||
~~~~~~~~~~~ | ||
|
||
None | ||
|
||
Maintenance and Refactorings | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
None | ||
|
||
Build | ||
~~~~~ | ||
|
||
None | ||
|
||
Documentation | ||
~~~~~~~~~~~~~ | ||
|
||
None | ||
|
||
Miscellaneous | ||
~~~~~~~~~~~~~ | ||
|
||
None |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.