Reputation: 781
I'm looking for a function that would count all of the different occcurrences of different strings within a range. It would go through an input range, cell by cell and, for each unique value it finds, it would count the number of occurrences of that value in the range.
So, for example, if I were to run it on this range:
I would get this result:
Thanks in advance for any help.
Upvotes: 0
Views: 215
Reputation: 152450
It would be easiest to create a pivot table, which will create the uniques list and the count:
Put the string column in both the rows and the values.
Upvotes: 3
Reputation: 78
The easiest way to do it is with =COUNTIF()
function.
The first argument it takes is the data range, the second - the value it will be seeking. So, for your example, the cells to count the Hellos, Goodbyes and Seeyas should look like that:
=COUNTIF(A1:A6, "Hello")
=COUNTIF(A1:A6, "Goodbye")
=COUNTIF(A1:A6, "See ya")
Upvotes: 0