In my data set, each row represents a student. For each student, I have the majors earned by that student. I need to generate a frequency count for each major over the whole data set.
In my toy data set (attached) each student can earn between one and three majors, and the set of possible majors is {HUMA, ENGI, NSCI, SOCS}. I need to be able to count the total number of occurrences of each type of major. See the little table below the toy data set -- that's the result I need.
In Tableau, I have kludged this by generating, for each student, for each major, four binary variables "is huma major", "is engi major" etc (that's 12 new variables per row), and then brute force adding stuff up. Not elegant. But the real problem is that my set of possible majors actually has about 50 elements (not just the 4 in my toy data set), so, in real life, my inelegant solution is a big mess.
Any help would be highly appreciated. Thanks
You ideally need to reshape your data to create two new columns - Major Number, and Major. You can do this by hand, by an Excel Plug-in, or through custom-SQL.
http://community.tableau.com/docs/DOC-5059
and