From a693228fb4ffcff11891bf39c3bf522cdb48ecd3 Mon Sep 17 00:00:00 2001 From: Kelsey Jordahl Date: Mon, 30 Sep 2013 21:43:58 -0500 Subject: [PATCH] BUG: GeoSeries can't use _data attribute with released pandas versions --- geopandas/geoseries.py | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/geopandas/geoseries.py b/geopandas/geoseries.py index 78c6416..f1886bf 100644 --- a/geopandas/geoseries.py +++ b/geopandas/geoseries.py @@ -514,7 +514,7 @@ class GeoSeries(Series): object.__setattr__(self, name, getattr(other, name, None)) return self - def copy(self, deep=True): + def copy(self, order='C'): """ Make a copy of this GeoSeries object @@ -528,10 +528,8 @@ class GeoSeries(Series): copy : GeoSeries """ # FIXME: this will likely be unnecessary in pandas >= 0.13 - data = self._data - if deep: - data = data.copy() - return GeoSeries(data)._propogate_attributes(self) + return GeoSeries(self.values.copy(order), index=self.index, + name=self.name)._propogate_attributes(self) def isnull(self): """Null values in a GeoSeries are represented by empty geometric objects"""