Combining columns of a dataframe

前端 未结 0 848
逝去的感伤
逝去的感伤 2020-12-18 13:23

I\'m trying to combine the columns of a dataframe like the following

df[\'new\'] = df[\'a\'].astype(str) + \':\' + df.b.astype(str) + \' \' + df.c.astype(str)         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题