【发布时间】:2019-01-13 15:07:48
【问题描述】:
TSV 文件包含一些用户事件数据:
user_uid category event_type
"11" "like" "post"
"33" "share" "status"
"11" "like" "post"
"42" "share" "post"
获取每个类别和每个 user_id 的 post 事件数量的最佳方法是什么?
我们应该显示以下输出:
user_uid category count
"11" "like" 2
"42" "share" 1
【问题讨论】:
标签: python python-3.x pandas dataset