a = df.drop_duplicates(subset=['微博id'],keep='first')
b = df.drop_duplicates(subset=['微博id'],keep=False)
f=a.append(b).drop_duplicates(subset=['微博id'],keep=False)
即将DataFrame中微博id这一series中的重复项挑出来了,f就是重复的
a = df.drop_duplicates(subset=['微博id'],keep='first')
b = df.drop_duplicates(subset=['微博id'],keep=False)
f=a.append(b).drop_duplicates(subset=['微博id'],keep=False)
即将DataFrame中微博id这一series中的重复项挑出来了,f就是重复的