Jump to content

Is there an Excel whizz in the house?


Sam Nichols

Recommended Posts

Gents,

I think this is a pretty straightforward task but it's been a long time since I played around with IF statements (I think that's what I need?!)

Basically I have three columns of numbers and I need to know which value is the smallest (I have 4,000 rows, so I'm not doing it manually!)

I'd like the final column to tell me which of my four columns has the lowest value, ideally by simply having the column header copied across.

The columns are FH, FC, MO, YR (Flight Hours, Flight Cycles, Months and Years), I've already converted them to a common unit.

Any ideas?

Link to comment
Share on other sites

The 'min' function will find the lowest value. The 'match' function will find the column position of the lowest value, and the 'index' function will help you get the column name, so you'll end up with something like:

=index(X$3:AB$3, match(min(X4:AB4), X4:AB4, 0)))

Edited by JD™
Link to comment
Share on other sites

Obviously I'm sure there is a better way of doing this, but so far this is what I've done...

http://oi57.tinypic.com/1z5kewg.jpg

It's a list of tasks that must all be completed by certain intervals, but the intervals are in different units. On the right I have converted the number of MO's into the number for FH's that occur in that unumber of Mo's, same for FC's. I've done the same thing with YE's.

Since posting the topic I've realised that the best way to compare the FC's and FH's will be using calendar dates so I'll do that afterwards.

So for now, I need to know which is smallest out of FH, MO IN FH and YE IN FH. Then I need to know which is smallest of FC, MO IN FC and YE IN FC.

Any ideas?

Link to comment
Share on other sites

Just wrap the whole thing in an if. So...

=if( min(X4:AB4)=0, "", index(X$3:AB$3, match(min(X4:AB4), X4:AB4, 0))))

That'll make the result column blank if there's a 0 involved, but won't give you the 'next smallest' value. That'd be a bit more involved, but doing some thinking around those functions should get you sorted :)

If you don't have it done by the weeked we can have a tipsy look at it Saturday night (Y)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...