Lookup value meeting criteria, return column heading

Askew

New Member
Joined
Apr 23, 2019
Messages
1
I am trying to search for a value >2 in a row, and return the column header of the cell which meets that criteria. Currently I have INDEX/MATCH/MAX to return the header, but I am having trouble making it conditional (>2). Below I have illustrated the desired result. What formula can I put in column E that will return this?


[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]H1[/TD]
[TD]H2[/TD]
[TD]H3[/TD]
[TD]Result[/TD]
[/TR]
[TR]
[TD]x[/TD]
[TD]1[/TD]
[TD]0[/TD]
[TD]1[/TD]
[TD]-[/TD]
[/TR]
[TR]
[TD]y[/TD]
[TD]0[/TD]
[TD]2[/TD]
[TD]1[/TD]
[TD]H2[/TD]
[/TR]
[TR]
[TD]z[/TD]
[TD]3[/TD]
[TD]0[/TD]
[TD]0[/TD]
[TD]H1[/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce
If you have Excel ver. 2010 or later try:
This formula assumes as in your example that only one number in the row can be above 2. If there could be multiple values in the row above 2 we would need to make some changes.
Copy formula down as needed.
Excel Workbook
ABCDE
1H1H2H3Result
2x101 
3y021
4z300H1
Sheet
 
Upvote 0
Askew, try this:
Code:
=IF(B2>=2,B$1,IF(C2>=2,C$1,IF(D2>=2,D$1,"-")))
In your question you stated you were looking for values >2 yet your example gives a result for =2 also.
If your just want >2 then delete the = sign from the above equation.
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,178
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top