【发布时间】:2010-06-21 15:54:37
【问题描述】:
如果我们有这样的问题(所有答案都是复选框),我必须做一份调查报告。
What is you favorite cake(s) (please choose more than one):
[] Tiramisù
[] Carrot Cake
[] Cupcake
然后调查软件像这样导出为 CSV:
"username","likes_tiramisu","likes_carrotcake","likes_cupcake"
"test01",1,1,1
"test02",0,1,1
"test03",0,1,0
"test04",0,0,1
我想制作一个条形图,其中每个直方图代表每个蛋糕的频率。 如何组合这样的表格:
"likes_tiramisu" "likes_carrotcake" "likes_cupcake"
1 3 3
我可以用每列中所有元素的总和来解决它吗? 它在概念上有效吗?
【问题讨论】:
-
I would like to make a barplot where every histogram represent the frequency of every cake.也许你的意思是...where every *bin* represents frequency...? -
是的,对不起...我的意思是每个垃圾箱。