Columns must be same length as key
unknown
python
4 years ago
450 B
1,153
Indexable
print(df.First.str.split(expand=True)) # gives me the following
0 1 2
Area Code
8074 John None None
9119 Jack None None
8075 John "Da Man"
91234 Stephen None None
298 NaN NaN NaN
123 Joan "Danger", Anne
# i want to keep only column 0, the instructor says to use
df.First = df.First.str.split(expand=True)
Editor is loading...