You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In [1]: float(pd.Series([1]))
Out[1]: 1.0
In [2]: int(pd.Series([1]))
Out[2]: 1
Raises a TypeError if there's more than one element, but not sure the exact use case for the single element case. int(ser.iloc[0]) should probably be preferred.
The text was updated successfully, but these errors were encountered:
+1; tangentially related - I've wondered what Series.bool and DataFrame.bool were for. They have similar logic (raise if there is more than one element).
Raises a
TypeError
if there's more than one element, but not sure the exact use case for the single element case.int(ser.iloc[0])
should probably be preferred.The text was updated successfully, but these errors were encountered: