From 1d0c4ffa1487e69027babca2458d7602f37cdee4 Mon Sep 17 00:00:00 2001 From: scottsanderson Date: Wed, 4 Jul 2012 03:47:58 -0400 Subject: [PATCH] :result --->results --- zipline/lines.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/zipline/lines.py b/zipline/lines.py index e29fccf8..768b1ef9 100644 --- a/zipline/lines.py +++ b/zipline/lines.py @@ -141,6 +141,7 @@ class SimulatedTrading(object): self.sim = config['simulator_class'](addresses) self.clients = {} + self.trading_client = TradeSimulationClient( self.trading_environment, self.sim_style, @@ -166,7 +167,7 @@ class SimulatedTrading(object): def create_test_zipline(**config): """ :param config: A configuration object that is a dict with: - + - environment - a \ :py:class:`zipline.finance.trading.TradingEnvironment` - allocator - a :py:class:`zipline.simulator.AddressAllocator` @@ -189,7 +190,7 @@ class SimulatedTrading(object): a SIMULATION_STYLE as defined in :py:mod:`zipline.finance.trading` """ assert isinstance(config, dict) - + allocator = config['allocator'] sid = config['sid'] @@ -306,8 +307,8 @@ class SimulatedTrading(object): def get_cumulative_performance(self): return self.trading_client.perf.cumulative_performance.to_dict() - def publish_to(self, result_socket): - self.trading_client.perf.publish_to(result_socket) + def publish_to(self, results_socket): + self.trading_client.perf.publish_to(results_socket) def allocate_sockets(self, n): """