Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default Help with complex If statement

I'm not sure if this is possible or not, but it's worth a try. I'm running
Excel 2003.

I'm trying to do all of this in one cell, rather than adding an additional
column. I have two columns that I want to compare. I want to count the
instances where the cells in column B are greater than the cells in column A.
For example:

A B
1 1 3
2 5 2
3 2 4
4 6 8
5 7 2

I want a formula that will show me a count of 3, because B1, B3, and B4 are
all greater than the corresponding rows in column A. I eventually want to end
up with a percentage of numbers in B that are greater than the numbers in A,
but once I can get the count formula figured out, the percentage will be
easy. I've been able to get this done with individual "if" statements in a
separate column, but I'd really like to know if there's a way to combine it
all into 1 formula. Any ideas are appreciated!!
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,718
Default Help with complex If statement

=SUMPRODUCT(--(B1:B5A1:A5))

The formula above returns 3


"GHawkins" wrote:

I'm not sure if this is possible or not, but it's worth a try. I'm running
Excel 2003.

I'm trying to do all of this in one cell, rather than adding an additional
column. I have two columns that I want to compare. I want to count the
instances where the cells in column B are greater than the cells in column A.
For example:

A B
1 1 3
2 5 2
3 2 4
4 6 8
5 7 2

I want a formula that will show me a count of 3, because B1, B3, and B4 are
all greater than the corresponding rows in column A. I eventually want to end
up with a percentage of numbers in B that are greater than the numbers in A,
but once I can get the count formula figured out, the percentage will be
easy. I've been able to get this done with individual "if" statements in a
separate column, but I'd really like to know if there's a way to combine it
all into 1 formula. Any ideas are appreciated!!

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 67
Default Help with complex If statement

There may be other ways of doing this but I would use:

=SUMPRODUCT(--(A1:A5<B1:B5))



"GHawkins" wrote in message
...
I'm not sure if this is possible or not, but it's worth a try. I'm running
Excel 2003.

I'm trying to do all of this in one cell, rather than adding an additional
column. I have two columns that I want to compare. I want to count the
instances where the cells in column B are greater than the cells in column
A.
For example:

A B
1 1 3
2 5 2
3 2 4
4 6 8
5 7 2

I want a formula that will show me a count of 3, because B1, B3, and B4
are
all greater than the corresponding rows in column A. I eventually want to
end
up with a percentage of numbers in B that are greater than the numbers in
A,
but once I can get the count formula figured out, the percentage will be
easy. I've been able to get this done with individual "if" statements in a
separate column, but I'd really like to know if there's a way to combine
it
all into 1 formula. Any ideas are appreciated!!



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
Another Extremely complex IF statement Teri Excel Worksheet Functions 2 January 29th 07 08:27 PM
complex IF(OR(...AND())) statement Dave F Excel Discussion (Misc queries) 2 October 4th 06 06:24 PM
Help with complex average/if statement [email protected] Excel Worksheet Functions 1 September 29th 06 07:33 PM
rather complex logic statement [email protected] Excel Worksheet Functions 6 March 31st 06 08:32 PM
Fairly Complex IF Statement Patrick Excel Worksheet Functions 3 May 9th 05 09:48 PM


All times are GMT +1. The time now is 10:58 AM.

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"