Array conditional must be same shape as self

我的未来我决定 提交于 2021-02-05 09:38:28

问题


I get this error when I attempt to compare to variable names such as:

compare = Search1.where(Search1UK>Search1DE)
compare
compare.fillna(0)

'Search1UK' and 'Search1DE' are both variable names in which I have assigned a name to identify columns within different data frames.

Anyone could help on this please?


回答1:


try:

compare = Search1.where(Search1['Search1UK']>Search1['Search1DE'])


来源:https://stackoverflow.com/questions/55163796/array-conditional-must-be-same-shape-as-self

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!