spyder中一直unsupported operand type(s) for-: 'float' and 'str'
3条回答 默认 最新
- CSDN专家-HGJ 2021-06-20 16:04关注
检查一下ypred,ytrue的数据类型,估计是test['date']中有字符串数据类型列。如有str类型的话,要先转换为float或int类型。
本回答被题主选为最佳回答 , 对您是否有帮助呢?解决 1无用
spyder中一直unsupported operand type(s) for-: 'float' and 'str'
检查一下ypred,ytrue的数据类型,估计是test['date']中有字符串数据类型列。如有str类型的话,要先转换为float或int类型。