Thread: find maximum
View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.misc
Frank Drost
 
Posts: n/a
Default find maximum

Thanks Ron. That command works.
However, I actually made a small, but crucial mistake in my query. I am not
actually after the second largest value, but its location in its row. For
instance, as in my example, the number 7 is the second largest value, and its
location in that row is nr 6. And then to make the complication complete, I
then want as answer the value of cell 6 in row X (x is a variable here, but
will often be the first row in my table). To do that I think I need to do
conditional formatting. It seems I have to use LARGE, but what else? Can you
help me with this?

Thanks.



"Ron Coderre" wrote:

Try this:
For your data in cells A1:J1

K1: =LARGE(A1:J1,2)

That returns the second largest value in the referenced range.

Does that help?

***********
Regards,
Ron

XL2002, WinXP-Pro


"Frank Drost" wrote:

In a table, I need to find for each row the second largest value. Undoubtedly
this can be done with conditional formatting, but I don't know how. Something
like find maximum for a range of cells as long no cell is the maximum of that
row, right? For instance, the following row has:
0 2 4 5 3 7 8 3 2 6
I want to have as answer nr 7 (8 is maximum, 7 is next highest)

does anyone know how to do that?

Thanks