Change column value if it does contain one of two substrings - getting a “Series objects are mutable - they cannot be hashed” error?

前端 未结 0 1442
遇见更好的自我
遇见更好的自我 2020-12-17 10:20
cand[~cand[\'Candidate Party\'].str.contains("Democrat|Republican"), \'Candidate Party\'] = "Other"

I have that line of code abo

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