If I have two rows of numbers...
5 10 15 20 25 30 35 40 45 50
1 16 23 18 64 28 46 72 18 26
Is there a formula I can insert, in another cell elsewhere on the sheet,
that will find the largest value in the second row, but return the
corresponding number from the first row? In the above example, I could use
"=max(b1:b10)" to find the largest number in row b, but how do I reference
row a?
Thanx.
Bob Phillips - 17 Nov 2005 20:25 GMT
=INDEX(1:Try,,MAX(2))

Signature
HTH
RP
(remove nothere from the email address if mailing direct)
> If I have two rows of numbers...
>
[quoted text clipped - 8 lines]
>
> Thanx.
Bob Phillips - 17 Nov 2005 20:26 GMT
Sorry, that response got messed.
Try this formula
=INDEX(1:1,,MATCH(MAX(2:2),2:2,0))

Signature
HTH
RP
(remove nothere from the email address if mailing direct)
> If I have two rows of numbers...
>
[quoted text clipped - 8 lines]
>
> Thanx.
Dave Peterson - 17 Nov 2005 20:27 GMT
One way:
=INDEX(A1:J1,MATCH(MAX(A2:J2),A2:J2))
(did you really mean rows of numbers or columns of numbers (=max(b1:b10))????
> If I have two rows of numbers...
>
[quoted text clipped - 8 lines]
>
> Thanx.

Signature
Dave Peterson
Dave Peterson - 17 Nov 2005 20:44 GMT
I left off a 0.
=INDEX(A1:J1,MATCH(MAX(A2:J2),A2:J2),0)
> One way:
>
[quoted text clipped - 18 lines]
>
> Dave Peterson

Signature
Dave Peterson
bpeltzer - 17 Nov 2005 20:28 GMT
You've started down the right path... MAX to get the max value in row 2,
then MATCH to find how far into the row that value is found, then INDEX to
get the corresponding entry from row 1. Something like
=index(A1:J1,match(max(A2:J2),A2:J2,false)).
> If I have two rows of numbers...
>
[quoted text clipped - 8 lines]
>
> Thanx.
Steven Sinclair - 17 Nov 2005 21:32 GMT
Cool...gettin' closer!
8^)>
Now, how can I accomplish the same feat, but instead of searching for the
largest number and giving me the corresponding number, search for the five
highest and give me the five corresponding numbers.
Thanx again.
Bob Phillips - 17 Nov 2005 23:13 GMT
=INDEX(1:1,,MATCH(LARGE(2:2,1),2:2,0))
=INDEX(1:1,,MATCH(LARGE(2:2,2),2:2,0))
etc.

Signature
HTH
RP
(remove nothere from the email address if mailing direct)
> Cool...gettin' closer!
>
[quoted text clipped - 5 lines]
>
> Thanx again.
Steven Sinclair - 17 Nov 2005 22:56 GMT
Anyone?
8^)>
Dave Peterson - 18 Nov 2005 01:34 GMT
What didn't work?
> Anyone?
>
> 8^)>

Signature
Dave Peterson