max, min and copy entire corresponding row

tomrus

New Member
Joined
Jul 5, 2008
Messages
5
I have 4 coloums D,E,F,G and I want to find the MAX and MIN of D4:D5203, E4:E5203, F4:F5203, G4:G5203. Then find the cell where the max and min occors and copy the entire row at the bottom of the sheet (or in e new sheet if it is easier). In other words I have max of the column D, then I want copy the row where it occours with the corresponding values, max column E and copy the row and so on. The same for the minimum, in total I shoud have 4 rows for the max and 4 for the min, hope someone can help. Many thanks!

Tom
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
what are the "corresponding values"

you can use MATCH(MAX(D:D),D:D,0) to find the row of the largest value in the given range -- then use in conjunction with say an OFFSET or INDEX to retrieve additional values based on given the row

=INDEX(A:A,MATCH(MAX(D:D),D:D,0),1)

would return value in A for row where MAX in D appears in D.
 
Upvote 0
thanks for the answer! What's the 0 at the end of MATCH(MAX(D:D),D:D,0)?

what are the "corresponding values"

For corresponding values I meant find max and copy all the other values in the row, regardless they're max, min or not.

you can use MATCH(MAX(D:D),D:D,0) to find the row of the largest value in the given range -- then use in conjunction with say an OFFSET or INDEX to retrieve additional values based on given the row


=INDEX(A:A,MATCH(MAX(D:D),D:D,0),1)

would return value in A for row where MAX in D appears in D.
 
Upvote 0
0 equates to boolean FALSE which forces MATCH to find first exact match in a given range.

So you may see written as MATCH(criteria,range,false) rather than MATCH(criteria,range,0)
 
Upvote 0

Forum statistics

Threads
1,214,784
Messages
6,121,538
Members
449,038
Latest member
Guest1337

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