Formula for Counts

menor59

Well-known Member
Joined
Oct 3, 2008
Messages
574
Office Version
  1. 2021
Platform
  1. Windows
Hello all,

formula needed for the following please if you can help

A1 B1 D1 E1
Dog fido Dog 4
dog jess Cat 3
dog rover
dog max
cat purr
cat kitty
cat jax



A1 is a list of Duplicates; lets call that a catagory
B1 are Names assigned to that catagory
D1 is A1 without Duplicates
E1 is needed to compare D1 to range A1 (Range) and count the number of names for dogs and cats..From B1

Please help
 
Last edited:

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
=SUM(--(C1=A1:A7))

It's an array formula so you have to Ctrl+Shift+Enter after paste.
 
Last edited by a moderator:
Upvote 0
with your sample data in A1:D7
This regular formula, copied down, returns the count of unique names for the referenced category:
Code:
E1: =SUMPRODUCT(ISNUMBER(SEARCH(D1,$A$1:$A$19))/COUNTIF($B$1:$B$19,$B$1:$B$19&""))
(Duplicate combinations are only counted once)

Is that something you can work with?
 
Last edited:
Upvote 0
Hello, are you looking for a COUNTIFS:

=COUNTIFS($A$1:$A$7,C1)

If you at looking for dog / cat unique names, can you use a Pivot Table?
 
Last edited:
Upvote 0

Forum statistics

Threads
1,223,577
Messages
6,173,162
Members
452,503
Latest member
AM74

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