Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Member
 
Posts: 33
Default Count unique items in groups

Hi all,

I'm looking to count unique items in column 2 within the groups in column 1.
e.g.
A......B
X......100
X......100
Y......200
Y......100
Y......200
Z......500

Required Output:
Y=2 (because of 100 and 200)
X=1 (because only 100)
Z=1 (because only 500)

I am totaly lost to find a solution so any help would be great.
Note i can't use a pivot due to the size of my worksheet.

GarToms
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default Count unique items in groups

Give you columns headings eg: Letter & Amount then use DataSubtotal - In the
"At each change in" box select "Name" then "Use Function" of Count then "add
subtotal to" the "Amount".

In the left of the screen you will see the numbers 123. Click on the 2 and
this will shrink the data to show totals only. You can then copy those
visable cells only to another sheet. Or alternatively you could research
"Pivot Tables" at the following site.
http://www.contextures.com/tiptech.html

"GarToms" wrote:


Hi all,

I'm looking to count unique items in column 2 within the groups in
column 1.
e.g.
A......B
X......100
X......100
Y......200
Y......100
Y......200
Z......500

Required Output:
Y=2 (because of 100 and 200)
X=1 (because only 100)
Z=1 (because only 500)

I am totaly lost to find a solution so any help would be great.
Note i can't use a pivot due to the size of my worksheet.

GarToms




--
GarToms

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
DOR DOR is offline
external usenet poster
 
Posts: 11
Default Count unique items in groups

Assume data are in A2:B7. Use helper column C. In C2 enter

=A2&B2 and copy down to C7.

Enter X,Y, Z in D2 to D4. In E4 enter

SUMPRODUCT(--($A$2:$A$7=D2),1/COUNTIF($C$2:$C$7,$C$2:$C$7))

and copy down to E4.

HTH

Declan

GarToms wrote:
Hi all,

I'm looking to count unique items in column 2 within the groups in
column 1.
e.g.
A......B
X......100
X......100
Y......200
Y......100
Y......200
Z......500

Required Output:
Y=2 (because of 100 and 200)
X=1 (because only 100)
Z=1 (because only 500)

I am totaly lost to find a solution so any help would be great.
Note i can't use a pivot due to the size of my worksheet.

GarToms




--
GarToms


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I set up a formula to count only unique items in a column? jennifer Excel Worksheet Functions 0 March 26th 06 11:55 PM
Function to count unique values? Richard Buttrey Excel Worksheet Functions 5 September 22nd 05 02:58 PM
Count Unique in Pivot Table Nelson Excel Discussion (Misc queries) 6 April 10th 05 10:05 PM
count duplicate (or, inversely, unique) entries, but based on a condition markx Excel Worksheet Functions 3 March 8th 05 06:57 PM
Pivot Table Unique Count bsantona Excel Worksheet Functions 1 February 11th 05 09:27 PM


All times are GMT +1. The time now is 08:34 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"