Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

remove repetitive characters from the specified column of a given DataFrame

cols = ["col1","col2","col3"]
de_dup = a[cols].loc[(a[cols].shift() != a[cols]).any(axis=1)]
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #remove #repetitive #characters #column #DataFrame
ADD COMMENT
Topic
Name
7+1 =