diff --git a/pandas/core/sparse/frame.py b/pandas/core/sparse/frame.py index d8c0aa41edac1..f30bd5c36a61b 100644 --- a/pandas/core/sparse/frame.py +++ b/pandas/core/sparse/frame.py @@ -5,7 +5,6 @@ from __future__ import division # pylint: disable=E1101,E1103,W0231,E0202 -from numpy import nan from pandas.compat import lmap from pandas import compat import numpy as np @@ -156,7 +155,7 @@ def _init_dict(self, data, index, columns, dtype=None): v = v.copy() else: if isinstance(v, dict): - v = [v.get(i, nan) for i in index] + v = [v.get(i, np.nan) for i in index] v = sp_maker(v) sdict[k] = v