Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 368
  • Last Modified:

Return count of values less than a value in another row

I have two rows:

Row 1: 5 4 3 4 3 4 4 5 4
Row 2: 4 5 5 3 4 4 4 4 3

I need to count the number of occurrences that a value in Row 2 is less than its corresponding column in Row 1.  

In other words, is Row 2/Column A less than Row 1/Column A and so on.

So in this example, the total count would be 3 (columns A, D, I).
0
mcnuttlaw
Asked:
mcnuttlaw
2 Solutions
 
Saqib Husain, SyedEngineerCommented:
=SUMPRODUCT(--(A1:I1<A2:I2))

BTW the answer should be 4
A, D, H, I
0
 
byundtCommented:
ssaqibh has the right approach, but inadvertently counted row 1 being less than row 2. He meant to say:
=SUMPRODUCT(--(A2:I2<A1:I1))
0
 
mcnuttlawAuthor Commented:
Awesome, thanks.

And I stand corrected!
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now