TestEmpiricalCDF error in new pandas
Closed this issue · 1 comments
jkitzes commented
In attempting clean install with newest pandas v0.16.2, TestEmpiricalCDF throws an error that appears to stem from the method of setting the keys for the index in empirical_cdf - one example of two errors:
======================================================================
ERROR: macroeco.empirical.test_empirical.TestEmpiricalCDF.test_all_data_same
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/jkitzes/miniconda/lib/python2.7/site-packages/nose/case.py", line 197, in runTest
self.test(*self.arg)
File "/media/sf_jkitzes/Projects/macroeco/macroeco/empirical/test_empirical.py", line 305, in test_all_data_same
res = emp.empirical_cdf(test_data)
File "/media/sf_jkitzes/Projects/macroeco/macroeco/empirical/_empirical.py", line 1182, in empirical_cdf
ecdf = ecdf.join(probs, how="right")
File "/home/jkitzes/miniconda/lib/python2.7/site-packages/pandas/core/frame.py", line 4019, in join
rsuffix=rsuffix, sort=sort)
File "/home/jkitzes/miniconda/lib/python2.7/site-packages/pandas/core/frame.py", line 4033, in _join_compat
suffixes=(lsuffix, rsuffix), sort=sort)
File "/home/jkitzes/miniconda/lib/python2.7/site-packages/pandas/tools/merge.py", line 38, in merge
return op.get_result()
File "/home/jkitzes/miniconda/lib/python2.7/site-packages/pandas/tools/merge.py", line 186, in get_result
join_index, left_indexer, right_indexer = self._get_join_info()
File "/home/jkitzes/miniconda/lib/python2.7/site-packages/pandas/tools/merge.py", line 259, in _get_join_info
left_ax.join(right_ax, how=self.how, return_indexers=True)
File "/home/jkitzes/miniconda/lib/python2.7/site-packages/pandas/core/index.py", line 2053, in join
return_indexers=return_indexers)
File "/home/jkitzes/miniconda/lib/python2.7/site-packages/pandas/core/index.py", line 2302, in _join_monotonic
join_index, ridx, lidx = self._left_indexer(other, self)
TypeError: Argument 'left' has incorrect type (expected numpy.ndarray, got Int64Index)