I want to extact the first 3
from values of a pandas column without doing a loop.
So,
df['myCol'][3]
5475
In order to extract the first 3 digits I do:
int(str(df['myCol'][3])[:2])
547
I want to apply to all the same procedure to the entire column. How can I do it?