Allow creation of TradingEnvironment to specify a minimum date, so that
trading days, market opens, etc. can trimmed to a range more relevant to
the backtest.
This changes is with an eye towards storing all market minutes in the
trading environment, where storing values for much more than the
simulation range starts to become more costly.
Replace it by distinguishing between "Loadable" and "Computable".
This is useful because it's now possible to write computable terms that
don't require any inputs (e.g. an `Always` filter or an `Everything`
classifier).
MAINT: make expected_cols class attributes.
MAINT: make concrete_loader a class attribute.
MAINT: drop sid column before creating loader.
TST: add method to fill df with event cases.
TST: move common case df into test_events.py.
TST: improve tests and fix error message assertions.
STY: fix whitespace.
DOC: update docs.
STY: fix style.
MAINT: clean up
STY: fix indentation.
MAINT: use different assertion method to check error message for python3.4 compatibility.
TST: refactor constants and clarify comments.
TST: clean up/extract constants in tests.
MAINT: add/modify constants.
MAINT: remove obsolete and alphabetize.
MAINT: clean up.
MAINT: modify constants to have named params.
MAINT: extract constants.
STY: fix indentation.
MAINT: refactor common part out of buyback_auth.
MAINT: refactor earnings test logic.
MAINT: clean up and improve docs.
BUG: fix imports.
MAINT: refactor test.
MAINT: change class name.
MAINT: remove error since won't be reached.
TST: improve and expand tests.
MAINT: change class name.
MAINT: change class name.
MAINT: extract string constants and remove error that won't be reached.
STY: fix line length.
MAINT: undo name change.
MAINT: add fields based on changes to events loader.
MAINT: modify based on expectations of events loader.
MAINT: modify args.
TST: clean up and clarify df access.
TST: fix bugs in test that didn't properly split datasets' data.
MAINT: fix merge error.
WIP: finish refactoring blaze events loader.
WIP: tests passing for earnings.
BUG: pass all kwargs explicitly for BlazeEventsCalendarLoader.
If this is not done, resources are not bound correctly.
MAINT: refactor for buyback_auth.
Fixes a bug where doing a boolean comparison between a non-numexpr
Filter and a NumExprFilter would fail because we don't implement
`__rand__` and `__ror__`.
So that consumers can write empty days worth of data, without needing
to construct a DataFrame with zero data force a write.
The internal loader uses `last_date_in_output_for_sid` to signify that
data has been attempted to be retrieved for all dates up until that, so
that when resuming a job those retrieval of data for those dates are not
re-attempted.
Also, used to make the write logic cleaneer, by making it only
necessary to create an array large enough for the given df.