Please support indexing with 0 dim np.array in df.iloc. · Issue #24919 · pandas-dev/pandas (original) (raw)
Code Sample, a copy-pastable example if possible
The code below works correctly.
df=pd.DataFrame([[1,2],[3,4]]) df.iloc[np.array([0])]
But the code below raises an error.
df.iloc[np.array(0)]
TypeError: object of type 'numpy.int64' has no len()