Skip to content

Instantly share code, notes, and snippets.

@sid321axn
Created August 3, 2020 12:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sid321axn/be0e4d9b503f78b0f550b9ce1af7cd9a to your computer and use it in GitHub Desktop.
Save sid321axn/be0e4d9b503f78b0f550b9ce1af7cd9a to your computer and use it in GitHub Desktop.
spec_chars = ["-","!",'"',"#","%","&","'","(",")",
"*","+",",","-",".","/",":",";","<",
"=",">","?","@","[","\\","]","^","_",
"`","{","|","}","~","–"]
for char in spec_chars:
df['title'] = df['title'].str.replace(char, '')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment