Is that any way that I can get first element of Seires without have information on index.
For example,We have a Series
import pandas as pd
key='MCS096'
SUBJECTS=pd.DataFrame({'ID':Series([146],index=[145]),\
'study':Series(['MCS'],index=[145]),\
'center':Series(['Mag'],index=[145]),\
'initials':Series(['MCS096'],index=[145])
})
prints out SUBJECTS:
print (SUBJECTS[SUBJECTS.initials==key]['ID'])
145 146
Name: ID, dtype: int64
How can I get the value here 146 without using index 145?
Thank you very much