counting unique values

mbernal

New Member
Joined
Apr 10, 2018
Messages
5
Hello - i am trying to write an equation that counts the number of unique values with a criteria associated with it. Below is an example data set, what I want to count is a number of unique animals (column A) but based on a criteria (column B). Using the below I would want an equation that counted the number of unique animals associated with Ed
Ed = 3 animals

Animal Person
Dog Ed
Cat Rob
Frog Jan
Monkey James
Dog Ed
Dog Rob
Cat Ed
Elephant Ed

Thanks!
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
This is an array formula and must be entered with CTRL-SHIFT-ENTER.
Excel Workbook
ABCD
1AnimalPersonPerson =Ed
2DogEdCount3
3CatRob
4FrogJan
5MonkeyJames
6DogEd
7DogRob
8CatEd
9ElephantEd
Sheet
 
Upvote 0
You're welcome.
You could add a 2nd criteria. How about an example of what you want to add.
 
Upvote 0
if we use the origional example but add a criteria in column C that says a Y or N. Then I would want the unique count of animals that is attributed to Ed and with a Y

AnimalPersonSentPerson =Ed
DogEdYCount2
CatRobY
FrogJanY
MonkeyJamesN
DogEdN
DogRobN
CatEdN
ElephantEdY

<tbody>
</tbody><colgroup><col><col span="2"><col><col></colgroup>
 
Upvote 0
Enter with CTRL-SHIFT-ENTER.
Excel Workbook
ABCDE
1AnimalPersonSentPerson =Ed
2DogEdYSent =Y
3CatRobYCount2
4FrogJanY
5MonkeyJamesN
6DogEdN
7DogRobN
8CatEdN
9ElephantEdY
Sheet
 
Upvote 0

Forum statistics

Threads
1,215,446
Messages
6,124,900
Members
449,194
Latest member
JayEggleton

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top