输出df.pivot:
Tags 350384 350385 350386 350387 350388 350389 350390 350391
UserID
693 0 1 0 1 0 0 0 1
730 0 0 0 0 0 0 0 0
906 0 0 0 2 0 0 0 2
1013 0 0 0 0 0 0 0 0
1284 0 0 0 0 0 0 0 0
我希望将其转换为以下形式:
UserID 350384 350385 350386 350387 350388 350389 350390 350391
693 0 1 0 1 0 0 0 1
730 0 0 0 0 0 0 0 0
906 0 0 0 2 0 0 0 2
1013 0 0 0 0 0 0 0 0
1284 0 0 0 0 0 0 0 0