Q:

how to get the number of elements in the specified collection equal to the specified object, underscore?

I use underscore library and wonder if I can get easily frequency of specific item in list.
For example, I have array:
var list = ['a', 'b', 'c', 'a'];

I want something like:
var count_a = /*returnCountFunction*/(list, 'a'); // 2.
var count_b = /*returnCountFunction*/(list, 'b'); // 1.

I'm interesting only use  underscoreJS.
Java has: Collections.frequency(list, "a");
[EDIT]
Actually I had complicated list of objects but I wrote:
$scope.getUniqueBiz = function(list){    
        return _.chain(list)
      .pluck('biz_name')
       .unique()
      .value();    
    };

Thanks, 

A:

_.countBy:

Sorts a list into groups and returns a count for the number of objects
  in each group.

So this:
result = _.countBy(list);

Returns this (on your list):

{a: 2, b: 1, c: 1}

From which you can grab:
result['a']; 

