Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
schillm228
 
Posts: n/a
Default nonadjacent selections

Why can't I use nonadjacent selections as a range in the =COUNTIF formula?

For example: =COUNTIF(FirstGroup,E53)
where FirstGroup is a nonadjacent selection of cells A10:A20 G10:G20


  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Domenic
 
Posts: n/a
Default nonadjacent selections

Here's one way...

=SUMPRODUCT(--(CHOOSE({1,2},A10:A20,G10:G20)=E53))

Hope this helps!

In article ,
schillm228 wrote:

Why can't I use nonadjacent selections as a range in the =COUNTIF formula?

For example: =COUNTIF(FirstGroup,E53)
where FirstGroup is a nonadjacent selection of cells A10:A20 G10:G20


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Harlan Grove
 
Posts: n/a
Default nonadjacent selections

Domenic wrote...
Here's one way...

=SUMPRODUCT(--(CHOOSE({1,2},A10:A20,G10:G20)=E53))


I'd figure the OP wants to use the defined name FirstGroup. Your
formula could be rewritten as

=SUMPRODUCT(--(CHOOSE({1,2},INDEX(FirstGroup,0,0,1),
INDEX(FirstGroup,0,0,2))=E53))

However, for counting, there's a more compact solution: FREQUENCY.

=INDEX(FREQUENCY(FirstGroup,E53*{0.99999999999999; 1}),2)

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Domenic
 
Posts: n/a
Default nonadjacent selections

I'd figure the OP wants to use the defined name FirstGroup.

Very true...

However, for counting, there's a more compact solution: FREQUENCY.

=INDEX(FREQUENCY(FirstGroup,E53*{0.99999999999999; 1}),2)


Nice one Harlan!
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Don Guillett
 
Posts: n/a
Default nonadjacent selections

try this idea
=SUMPRODUCT(COUNTIF(INDIRECT({"a2:a22","c2:c22"}), "=ff"))
=SUMPRODUCT(COUNTIF(INDIRECT({"a2:a22","c2:c22"}), E7))
--
Don Guillett
SalesAid Software

"schillm228" wrote in message
...
Why can't I use nonadjacent selections as a range in the =COUNTIF formula?

For example: =COUNTIF(FirstGroup,E53)
where FirstGroup is a nonadjacent selection of cells A10:A20 G10:G20






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
keyboard command used to select a range of nonadjacent cells? Jessizzle123 Excel Discussion (Misc queries) 2 November 9th 05 09:19 PM
keyboard command used to select a range of nonadjacent cells? Ron Coderre Excel Discussion (Misc queries) 0 November 9th 05 07:16 PM
functions with nonadjacent cells PCdummy Excel Worksheet Functions 1 August 29th 05 03:59 PM
Use TREND function with nonadjacent cells BonesCCS Excel Worksheet Functions 0 August 4th 05 10:59 PM
I cannot select nonadjacent cells in Excell Office XP SP2 rjohnson97127 Excel Discussion (Misc queries) 2 January 12th 05 06:59 PM


All times are GMT +1. The time now is 06:07 AM.

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"