@@ -12,14 +12,17 @@ Highlights
12
12
* Major performance enhancements.
13
13
* Dynamic history.
14
14
* New user defined method: ``before_trading_start``.
15
- * New api function: ``schedule_function``.
15
+ * New api function: :func:`~zipline.api.schedule_function`.
16
+ * New api function: :func:`~zipline.api.get_environment`.
17
+ * New api function: :func:`~zipline.api.set_max_leverage`.
18
+ * New api function: :func:`~zipline.api.set_do_not_order_list`.
16
19
* Pipeline API.
17
20
* Support for trading futures.
18
21
19
22
Enhancements
20
23
~~~~~~~~~~~~
21
24
22
- * Account object: Adds an account object to conext to track information about
25
+ * Account object: Adds an account object to context to track information about
23
26
the trading account.
24
27
Example:
25
28
@@ -107,14 +110,35 @@ Enhancements
107
110
the user to schedule a function to be called based on more complicated rules
108
111
about the date and time. For example, call the function 15 minutes before
109
112
market close respecting early closes (:issue:`411`).
110
- * Adds a list of leveraged ETFs and a waay to mark a 'do not trade' set of
111
- assets (:issue:`478`).
113
+ * New api function :func:`set_do_not_order_list`. This function accepts a list
114
+ of assets and adds a trading guard that prevents the algorithm from
115
+ trading them. Adds a list point in time list of leveraged ETFs that people may
116
+ want to mark as 'do not trade' (:issue:`478`).
112
117
* Adds a class for representing securities. :func:`~zipline.api.order` and other
113
118
order functions now require an instance of ``Security``
114
119
instead of an int or string (:issue:`520`).
115
120
* Generalize the ``Security`` class to :class:`~zipline.assets.Asset`. This is
116
121
in preperation of adding support for other asset types (:issue:`535`).
117
-
122
+ * New api function :func:`~zipline.api.get_environment`. This function by
123
+ default returns the string ``'zipline'``. This is used so that algorithms can
124
+ have different behavior on Quantopian and local zipline (:issue:`384`).
125
+ * Extends :func:`~zipline.api.get_environment` to expose more of the environment
126
+ to the algorithm. The function now accepts an argument that is the field to
127
+ return. By default, this is ``'platform'`` which returns the old value of
128
+ ``'zipline'`` but the following new fields can be requested:
129
+
130
+ - ``''arena'``: Is this live trading or backtesting?
131
+ - ``'data_frequency'``: Is this minute mode or daily mode?
132
+ - ``'start'``: Simulation start date.
133
+ - ``'end'``: Simulation end date.
134
+ - ``'capital_base'``: The starting capital for the simulation.
135
+ - ``'platform'``: The platform that the algorithm is running on.
136
+ - ``'*'``: A dictionary containing all of these fields.
137
+
138
+ (:issue:`449`).
139
+ * New api function :func:`~zipline.api.set_max_leveraged`. This method adds a
140
+ trading guard that prevents your algorithm from over leveraging itself
141
+ (:issue:`552`).
118
142
119
143
Experimental Features
120
144
~~~~~~~~~~~~~~~~~~~~~
@@ -123,7 +147,7 @@ Experimental Features
123
147
124
148
Experimental features are subject to change.
125
149
126
- * Adds new Pipeline API. The pipeline AAPI is a high-level declarative API for
150
+ * Adds new Pipeline API. The pipeline API is a high-level declarative API for
127
151
representing trailing window computaions on large datasets (:issue:`630`).
128
152
* Adds support for futures trading (:issue:`637`).
129
153
* Adds Pipeline loader for blaze expressions. This allows users to pull data
0 commit comments