[IPython-dev] How to search out all Zip codes and replace with the first 2 digits, in a Pandas dataframe, with the use of regex?

David Shi davidgshi at yahoo.co.uk
Mon Mar 20 10:54:50 EDT 2017


Hi, there,
Can anyone help?
How to search out all Zip codes and replace with the first 2 digits, in a Pandas dataframe, with the use of regex?

For instance, a ZIP code 33132 was found and replaced with 33.
Looking forward to hearing from you.
Regards.
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ipython-dev/attachments/20170320/c2f6a135/attachment.html>


More information about the IPython-dev mailing list