From 98e2448277e05c3563bfbdba5ee122c88951fc8c Mon Sep 17 00:00:00 2001 From: Andrew Liang Date: Mon, 6 Apr 2015 13:43:46 -0400 Subject: [PATCH] BUG: Replaced deprecated operators for pd.Index Replaced + and - with union and difference, respectively --- zipline/history/history_container.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/zipline/history/history_container.py b/zipline/history/history_container.py index 35860d2311..8fc19b62c5 100644 --- a/zipline/history/history_container.py +++ b/zipline/history/history_container.py @@ -535,7 +535,7 @@ def add_sids(self, to_add): Add new sids to the container. """ self.sids = pd.Index( - sorted(self.sids + _ensure_index(to_add)), + sorted(self.sids.union(_ensure_index(to_add))), ) self._realign_sids() @@ -544,7 +544,7 @@ def drop_sids(self, to_drop): Remove sids from the container. """ self.sids = pd.Index( - sorted(self.sids - _ensure_index(to_drop)), + sorted(self.sids.difference(_ensure_index(to_drop))), ) self._realign_sids()