Hi Zach,
Thanks for your reply! Here's the info:
1) IDL 8.5 and IDL 8.5.1 on RHEL6.4, 64 bit
2) Anaconda with Python 2.7
3) Here's the same lines of code that I tested with both 8.5 and 8.5.1. I got the same error for both:
pd = python.import('pandas')
df = pd.DataFrame(data=[[1,2],[3,4]], columns = ['c1','c2'])
x = df.iLoc[0]
% Python : Unable to index object of type: "_iLocIndexer"
When I run these same codes but use the python notation, the iLoc call does work.
>>> import pandas as pd
>>> df = pd.DataFrame(data=[[1,2],[3,4]], columns = ['c1','c2'])
>>> print (df)
c1 c2
0 1 2
1 3 4
>>> x=df.iLoc[0]
>>>print(x)
c1 1
c2 2
Name: 0, dtype: int64
Hope that brings some insight!
-Malia
|