Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 42
Default Array formula for unique values

Worked like a charm. Thanks.

Dan

"T. Valko" wrote:

Try this:

D1 = AA
D2 = AB
D3 = AC

Array entered in E1:

=SUM(N(FREQUENCY(IF(A$1:A$12=D1,MATCH(B$1:B$12,B$1 :B$12,0)),MATCH(B$1:B$12,B$1:B$12,0))0))

Copy down to E3

Biff

"Dan Hatola" wrote in message
...
I am trying to create an array formula that will allow me to count the
unique
values in Range2 if the value in Range1 matches a given value. Normally,
I
would use an array formula like =sum(1/countif(Range2,Range2)) to count
uniques however when I tried to add the conditional component to it, I got
a
#VALUE! error.

Here is the array formula I tried:
=sum(1/countif(if(Range1="AA", Range2),if(Range1="AA", Range2)))

Range1 Range2
AA 1
AA 2
AA 3
AA 4
AB 1
AB 1
AB 2
AB 2
AC 1
AC 2
AC 3
AC 2

Below is the output I would like to create (one formula next to each set
of
letters):

AA 4
AB 2
AC 3

Any help would be greatly appreciated.

Dan




  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Array formula for unique values

You're welcome. Thanks for the feedback!

Biff

"Dan Hatola" wrote in message
...
Worked like a charm. Thanks.

Dan

"T. Valko" wrote:

Try this:

D1 = AA
D2 = AB
D3 = AC

Array entered in E1:

=SUM(N(FREQUENCY(IF(A$1:A$12=D1,MATCH(B$1:B$12,B$1 :B$12,0)),MATCH(B$1:B$12,B$1:B$12,0))0))

Copy down to E3

Biff

"Dan Hatola" wrote in message
...
I am trying to create an array formula that will allow me to count the
unique
values in Range2 if the value in Range1 matches a given value.
Normally,
I
would use an array formula like =sum(1/countif(Range2,Range2)) to count
uniques however when I tried to add the conditional component to it, I
got
a
#VALUE! error.

Here is the array formula I tried:
=sum(1/countif(if(Range1="AA", Range2),if(Range1="AA", Range2)))

Range1 Range2
AA 1
AA 2
AA 3
AA 4
AB 1
AB 1
AB 2
AB 2
AC 1
AC 2
AC 3
AC 2

Below is the output I would like to create (one formula next to each
set
of
letters):

AA 4
AB 2
AC 3

Any help would be greatly appreciated.

Dan






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
Find a range of values in a range of cells Jack Taylor Excel Worksheet Functions 20 November 25th 06 01:26 PM
Lookup Data in two seperate Spreadsheets Padraig Excel Worksheet Functions 6 June 28th 06 03:05 PM
lookup a list of values for an array formula Xbrokylnboy Excel Worksheet Functions 0 June 19th 06 08:12 PM
Positioning Numeric Values Resulting from 6 Column Array Formula Sam via OfficeKB.com Excel Worksheet Functions 2 January 5th 06 02:03 AM
array formula values TUNGANA KURMA RAJU Excel Discussion (Misc queries) 1 September 29th 05 08:01 PM


All times are GMT +1. The time now is 12:13 PM.

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

About Us

"It's about Microsoft Excel"