Advertisement
Guest User

Untitled

a guest
Sep 22nd, 2019
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.14 KB | None | 0 0
  1. #extract value from text column into new column with regex pattern
  2. df['new_col'] = df['string_col'].str.extract((r'(DV.+\d*)MSRP'), expand=True)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement