标签: pandas mean fillna
我使用以下方法检查了数据集中的缺失值总和:
countries_new.isnull().sum()
现在,我尝试了以下操作: countries_new['Net migration'] = countries_new['Net migration'].fillna((countries_new['Net migration'].mean()))
countries_new['Net migration'] = countries_new['Net migration'].fillna((countries_new['Net migration'].mean()))
我收到类型错误消息:只能将星号(而不是“ int”)连接到str