ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Max and lookups (https://www.excelbanter.com/excel-worksheet-functions/93659-max-lookups.html)

ajayb

Max and lookups
 
Hi,

Can anyone help me with this?

2 3 4 5 6 7 8
73 120 98 56 45 89 84
108 110 73 130 98 56 45
89 84 108 93 73 120 98

I have the following table of data and I want to look in each row to find
the highest value (which I would do with Max I guess), then return the number
at the top of the column for that number.

Eg Row 2 highest number 120 value in top row 3
Row 3 Highest number 130 value in top row 5

Have tried Lookups but not having much success. Any ideas would be
gratefully appreciated.

Andy


Bob Phillips

Max and lookups
 
=INDEX($A$1:$G$1,,MATCH(MAX(A2:G2),A2:G2,0))

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"ajayb" wrote in message
...
Hi,

Can anyone help me with this?

2 3 4 5 6 7 8
73 120 98 56 45 89 84
108 110 73 130 98 56 45
89 84 108 93 73 120 98

I have the following table of data and I want to look in each row to find
the highest value (which I would do with Max I guess), then return the

number
at the top of the column for that number.

Eg Row 2 highest number 120 value in top row 3
Row 3 Highest number 130 value in top row 5

Have tried Lookups but not having much success. Any ideas would be
gratefully appreciated.

Andy




ajayb

Max and lookups
 
Marvellous Bob, it works a treat.

Thanks

Andy

"Bob Phillips" wrote:

=INDEX($A$1:$G$1,,MATCH(MAX(A2:G2),A2:G2,0))

--
HTH

Bob Phillips

(replace somewhere in email address with gmail if mailing direct)

"ajayb" wrote in message
...
Hi,

Can anyone help me with this?

2 3 4 5 6 7 8
73 120 98 56 45 89 84
108 110 73 130 98 56 45
89 84 108 93 73 120 98

I have the following table of data and I want to look in each row to find
the highest value (which I would do with Max I guess), then return the

number
at the top of the column for that number.

Eg Row 2 highest number 120 value in top row 3
Row 3 Highest number 130 value in top row 5

Have tried Lookups but not having much success. Any ideas would be
gratefully appreciated.

Andy






All times are GMT +1. The time now is 03:13 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com