Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

split a column in pandas

subevents = []
for element in events["Acheteur public"]:
    subevents.append(element.split(': ', 1)[1])

acheteurs = pd.DataFrame (subevents, columns = ['Acheteur public'])
acheteurs.head()
 
PREVIOUS NEXT
Tagged: #split #column #pandas
ADD COMMENT
Topic
Name
7+2 =