我有以下流Dataframe
+-----------------------------------------------------------------------
|______name__________________|______orderOfHobbies_____________________|
| Liza | [singing, painting] |
| Inter | [singing, singing] |
| Ovin | [singing, playing, reading, singing] |
------------------------------------------------------------------------
我想找到每个学生最喜欢的爱好。如果每个学生每个爱好的发生率相等,那么我想放弃这个记录。莉莎的记录将被取消。由于唱歌是经常发生在国际米兰和奥文唱歌将是最喜爱的爱好。
预期产量
+----------------------------------------------------
|______name__________________|______favoriteHobby___|
| Inter | singing |
| Ovin | singing |
-----------------------------------------------------
1条答案
按热度按时间bvpmtnay1#
您可以使用自定义项: