Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG: Series.get w boolean accessor #7407

jreback opened this issue Jun 9, 2014 · 0 comments


None yet
1 participant
Copy link

commented Jun 9, 2014

from ML:!topic/pydata/CDnF9cNR2ho

In [10]: df=pd.DataFrame({'i':[0]*10, 'b':[False]*10})

In [11]: vc_i=df.i.value_counts()

In [12]: vc_i.get(99,default='Missing')
Out[12]: 'Missing'

In [13]: vc_b=df.b.value_counts()

In [14]: vc_b
False    10
dtype: int64

In [15]: vc_b.get(False,default='Missing')
Out[15]: 10

In [16]: vc_b.get(True,default='Missing')

IndexError: index out of bounds
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.