Richard Frank
e8d60d9f75
SEC: Rotate secure vars for anaconda tokens
2017-05-09 11:28:55 -04:00
Andrew Daniels
a1efd56850
Merge pull request #1785 from quantopian/reindex-reader-get-value
...
Fixes equity history calls on the futures calendar
2017-05-09 10:33:58 -04:00
Andrew Daniels
d155d894fe
MAINT: Pass data_frequency to get_history_window
...
This allows us to remove the check for whether the provided dt had a
time of midnight, which was a flimsy way to infer if the data frequency
was 'daily'. Besides the explicit check being preferable, this method
was broken on the futures calendar, since midnight is a valid market
minute.
2017-05-09 09:34:39 -04:00
Andrew Daniels
423a76730c
BUG: Fix _handle_minute_history_out_of_bounds for future calendar
...
Need to use minute_to_session_label to retrieve the proper session.
2017-05-09 09:34:38 -04:00
Andrew Daniels
a4f1171f1f
TST: Adds MinuteEquityHistoryFuturesCalendarTestCase
...
Added as a subclass of MinuteEquityHistoryTestCase, where the primary
calendar is 'us_futures'.
Notes on modifications to MinuteEquityHistoryTestCase:
- To work on generic calendars, many tests now use set minutes for
window start and end, and check the values on active equity minutes.
- test_minute_regular should test against active equity minutes
- Adapts test_minute_midnight to work with futures calendar
- Use a method of getting the last open minute that works with
calendars that are open at midnight
- Test against Sunday at midnight, since the real intention of this
test is to check that given a non-open minute, we fall back to the
last open minute.
2017-05-09 09:34:38 -04:00
Andrew Daniels
b2a39b4ae4
TST: Adds DailyEquityHistoryOnFuturesCalendarTestCase
...
Added as a minimal subclass of DailyEquityHistoryTestCase, swapping out
just the primary calendar. This requires significant modifications to
DailyEquityHistoryTestCase, to allow for a generic primary calendar.
2017-05-09 09:34:38 -04:00
Andrew Daniels
f088afc1e1
MAINT: Modify ReindexBarReader.get_value to handle missing data
...
Instead of raising an exception, return 0.0 for volume, and nan for
everything else.
2017-05-09 09:34:37 -04:00
Freddie Vargus
caed14adcc
Merge pull request #1746 from quantopian/update-transaction-repr
...
MAINT: Add better repr for transactions
2017-05-08 14:54:24 -04:00
Richard Frank
e496b67894
Merge pull request #1783 from quantopian/slippage-cleanup
...
Slippage cleanup
2017-05-05 14:36:25 -04:00
Richard Frank
45c48afa8e
MAINT: allowed_asset_types is already defined in the base class
2017-05-05 14:09:02 -04:00
Richard Frank
0e0cb2f343
BUG: Fixed abstractness of MarketImpactBase
2017-05-05 14:09:02 -04:00
Richard Frank
ca2e3a04f3
MAINT: process_order is a method
...
and call super's __init__ to set up base state
2017-05-05 14:09:01 -04:00
Andrew Daniels
611f1702c7
Merge pull request #1780 from quantopian/include-diff-in-daily-bars-assertion
...
MAINT: Display diff if input to daily bar writer has gaps/extra bars
2017-05-04 10:48:08 -04:00
Andrew Daniels
b3c1cd5535
MAINT: Display diff if input to daily bar writer has gaps/extra bars
2017-05-04 10:19:09 -04:00
Andrew Daniels
0d9f4d29f5
MAINT: Handle gaps in input to daily bars writer ( #1778 )
...
Previously, a dataframe passed into BcolzDailyBarWriter.write that was
missing an expected session between its first and last sessions would be
written incorrectly. Upon converting the dataframe to a ctable, the
values for all days following the gap would be shifted backwards, and
nans would be shifted in at the end.
This commit handles the issue by asserting that the number of rows in
the input table matches the number of sessions in the calendar between
the table's first and last sessions.
Also fixes a test that was mistakenly using minutes_in_range where it
should have been using sessions_in_range (uncovered by this change).
2017-05-03 20:49:22 -04:00
David Michalowicz
96759be445
Merge pull request #1779 from quantopian/silver-chains
...
Gold/Silver futures contracts only trade certain months
2017-05-03 17:18:56 -04:00
dmichalowicz
191a1b729f
BUG: Gold and silver futures contracts only trade certain months
2017-05-03 16:34:01 -04:00
Freddie Vargus
e0433c4718
MAINT: Add better repr for transactions
...
Flake8
2017-04-28 11:13:40 -04:00
David Michalowicz
c61fd0ef07
Merge pull request #1770 from quantopian/zero-transaction-volume
...
Futures slippage model could have zero transaction volume
2017-04-26 13:59:33 -04:00
dmichalowicz
6beb4d6a36
BUG: Futures slippage model could have zero transaction volume
2017-04-26 13:35:00 -04:00
Jean Bredeche
c36b2ea680
Merge pull request #1769 from quantopian/py3-warnings
...
BUG: Python3 compatibility.
2017-04-26 10:46:34 -04:00
Jean Bredeche
c7250d3207
BUG: Python3 compatibility.
2017-04-26 10:47:27 -04:00
Jean Bredeche
c03aafbd0e
Merge pull request #1768 from quantopian/shim-portfolio-access-by-int
...
BUG: Add backwards compatibility for position lookup by int.
2017-04-26 10:13:16 -04:00
Jean Bredeche
b55d4bd423
BUG: Add backwards compatibility for position lookup by int.
2017-04-26 09:55:05 -04:00
Scott Sanderson
3c4f6e69f3
Merge pull request #1764 from quantopian/fix-docstring-typo2
...
DOC: Close backticks in docstring.
2017-04-25 22:52:28 -04:00
Scott Sanderson
3bcd4d4ac0
DOC: Close backticks in docstring.
2017-04-25 22:32:11 -04:00
David Michalowicz
a59eac9572
Merge pull request #1763 from quantopian/slippage-allowed-types
...
Don't require custom models to define allowed types
2017-04-25 19:40:41 -04:00
dmichalowicz
62c03a757f
API: Don't require custom models to define allowed types
2017-04-25 18:44:31 -04:00
David Michalowicz
3af85a65a5
Merge pull request #1748 from quantopian/slippage-futures-api
...
Add slippage and commission models for futures
2017-04-25 17:55:16 -04:00
dmichalowicz
dd21346eca
API: Add slippage and commission models for futures
2017-04-25 17:29:41 -04:00
Andrew Daniels
0da8a59f4c
Merge pull request #1762 from quantopian/quarterly-currency-futures
...
MAINT: Use a quarterly cycle for JY, CD, AD, and BP continuous futures
2017-04-25 15:52:56 -04:00
Andrew Daniels
88398236ff
MAINT: Use March quarterly cycle for JY, CD, AD, & BP continuous futures
...
The March, June, September, and December contracts for these futures
contain most of the trading activity, so we exclude the other more
sparsely traded contracts from the chain.
2017-04-25 15:31:33 -04:00
Jean Bredeche
8322423dc8
Merge pull request #1761 from quantopian/futures-cashflow-bugfix
...
BUG: use isinstance
2017-04-24 17:06:34 -04:00
Jean Bredeche
bed00a1b77
BUG: use isinstance
2017-04-24 17:06:26 -04:00
Jean Bredeche
88fc696398
Merge pull request #1757 from quantopian/futures-commissions
...
Assets everywhere ... and a futures fix.
2017-04-24 16:31:57 -04:00
Jean Bredeche
15d8dc93a3
MAINT: PR feedback.
2017-04-24 15:41:23 -04:00
Jean Bredeche
8c5e4b7bbc
BUG: Blotter should process as many splits as it can
2017-04-24 15:41:23 -04:00
Jean Bredeche
64746b186b
BUG: get_splits should return empty list, not empty dict
2017-04-24 15:41:23 -04:00
Jean Bredeche
5305fbe471
REF: Remove assetfinder from PerformancePeriod
2017-04-24 15:41:22 -04:00
Jean Bredeche
9a0d9d868c
REF: Remove asset_finder and multipliers from PositionTracker
2017-04-24 15:41:22 -04:00
Jean Bredeche
e429664fa6
REF: Blotter no longer needs AssetFinder
2017-04-24 15:41:21 -04:00
Jean Bredeche
59a96bf782
REF: Make dataportal emit splits that hold Assets, not sids
2017-04-24 15:41:21 -04:00
Jean Bredeche
1f8e194e09
BUG: Position cost basis was calculated incorrectly for Futures
...
For futures, we need to divide the position’s commission by the
contract size to get a per-unit commission in order to properly update
the position’s cost basis.
2017-04-24 15:41:20 -04:00
Jean Bredeche
b1248cb6d6
REF: Explicitly use Assets in Position, Order, Transaction
...
(Instead of `sid`, which were already usually assets)
Perf packets are unchanged and still emit `sid`: int
2017-04-24 15:41:13 -04:00
Jean Bredeche
123398d0e4
Merge pull request #1760 from quantopian/constant-futures
...
TST: New fixture for constant futures data
2017-04-24 14:33:47 -04:00
Jean Bredeche
ec6492c84e
TST: New fixture for constant futures data
2017-04-24 14:15:26 -04:00
David Michalowicz
2f87f548ba
Merge pull request #1755 from quantopian/schedule-function-calendar
...
Add calendar factory for the schedule_function API
2017-04-24 10:07:30 -04:00
dmichalowicz
f3086c548d
API: Add factory for calendars
2017-04-24 09:37:32 -04:00
David Michalowicz
35c3cf0eb7
Merge pull request #1754 from quantopian/premature-continuous-futures-2
...
Allow gaps between auto close and start date
2017-04-21 16:34:53 -04:00
dmichalowicz
67dd149660
BUG: Ordered contracts could end prematurely
2017-04-21 15:52:21 -04:00