I have a column of strings that include two unique columns - a column of two letters, and then a column of Y or E. In both cases they're not always filled. I'm hoping to split them into two new columns:
import pandas as pd
d={'col1':['AD','Y','E','AD E','WZ E'],
'col1_new':['AD','','','AD','WZ'],
'col2_new':['','Y','E','E','E']}
pd.DataFrame(d)
Any tips?