我正在尝试将此操作应用于我的数据框 df:
df[df.a, 'b'] = df.c*df.b
其中 a、b、c 的数据类型为:
a: bool b: float64 c: float64
但我收到错误TypeError: 'Series' objects are mutable, thus they cannot be hashed
TypeError: 'Series' objects are mutable, thus they cannot be hashed
发生这种情况是因为 b 列或 c 列中存在 na 值吗?如果是,有没有办法忽略 na 值的操作?
谢谢。
繁花如伊
相关分类