merchant = merchant.loc[merchant['merchant_id'].drop_duplicates().index.tolist()].reset_index(drop=True)#获得索引然后提取这些索引的数据,
#然后再重新设置索引,为什么要tolist()
#
drop_duplicates去重的操作
最新推荐文章于 2023-03-19 22:58:43 发布
merchant = merchant.loc[merchant['merchant_id'].drop_duplicates().index.tolist()].reset_index(drop=True)#获得索引然后提取这些索引的数据,
#然后再重新设置索引,为什么要tolist()
#