+ Reply to Thread
Results 1 to 4 of 4

Lookup column headings?

Hybrid View

  1. #1
    RunsWithKnives
    Guest

    Lookup column headings?

    Hi Folks,
    I have a Spread sheet that is 1430 rows deep by 39 columns long. I have
    extracted from this the min value of each row into another spread sheet. Now
    I want to use these min values to look back at the original spread sheet and
    find what column the min value came from (i.e. its heading)
    I’ve tried many machinations of hlookups, index, match but I can’t seem to
    get the thing to work,
    Cheers in advance,


  2. #2
    Max
    Guest

    Re: Lookup column headings?

    One way ..

    Assume source data in Sheet1, within cols B to AN (39 cols),
    with col headers in B1:AN1, data from row2 down

    In Sheet2,

    Placed in say, B2:
    =INDEX(Sheet1!$B$1:$AN$1,MATCH(MIN(Sheet1!B2:AN2),Sheet1!B2:AN2,0))
    would return the col header corresponding to the min value for row2 in Sheet1

    Copy B2 down by 1430 rows to return for all data rows in Sheet1

    Note that in the event of any ties in the min value within each row, only
    the leftmost col header will be returned
    --
    Max
    Singapore
    http://savefile.com/projects/236895
    xdemechanik
    ---
    "RunsWithKnives" wrote:
    > Hi Folks,
    > I have a Spread sheet that is 1430 rows deep by 39 columns long. I have
    > extracted from this the min value of each row into another spread sheet. Now
    > I want to use these min values to look back at the original spread sheet and
    > find what column the min value came from (i.e. its heading)
    > I’ve tried many machinations of hlookups, index, match but I can’t seem to
    > get the thing to work,
    > Cheers in advance,
    >


  3. #3
    RunsWithKnives
    Guest

    Re: Lookup column headings?

    Cheers Max,
    Not exactly what I was after as I already had the minimum values but gave me
    enough to work with. I ended up using
    =INDEX(Sheet1!$B$1:$AN$1,MATCH(Sheet2!B2,Sheet1!B2:AN2,0)) where Sheet2!B2
    was my list of values.

    Thanks again,

    RunsWithKnives

    "Max" wrote:

    > One way ..
    >
    > Assume source data in Sheet1, within cols B to AN (39 cols),
    > with col headers in B1:AN1, data from row2 down
    >
    > In Sheet2,
    >
    > Placed in say, B2:
    > =INDEX(Sheet1!$B$1:$AN$1,MATCH(MIN(Sheet1!B2:AN2),Sheet1!B2:AN2,0))
    > would return the col header corresponding to the min value for row2 in Sheet1
    >
    > Copy B2 down by 1430 rows to return for all data rows in Sheet1
    >
    > Note that in the event of any ties in the min value within each row, only
    > the leftmost col header will be returned
    > --
    > Max
    > Singapore
    > http://savefile.com/projects/236895
    > xdemechanik
    > ---
    > "RunsWithKnives" wrote:
    > > Hi Folks,
    > > I have a Spread sheet that is 1430 rows deep by 39 columns long. I have
    > > extracted from this the min value of each row into another spread sheet. Now
    > > I want to use these min values to look back at the original spread sheet and
    > > find what column the min value came from (i.e. its heading)
    > > I’ve tried many machinations of hlookups, index, match but I can’t seem to
    > > get the thing to work,
    > > Cheers in advance,
    > >


  4. #4
    Max
    Guest

    Re: Lookup column headings?

    Glad you got it working fine there
    Thanks for the feedback ..
    --
    Max
    Singapore
    http://savefile.com/projects/236895
    xdemechanik
    ---
    "RunsWithKnives" wrote:
    > Cheers Max, Not exactly what I was after as I already had
    >the minimum values but gave me enough to work with.
    > I ended up using =INDEX(Sheet1!$B$1:$AN$1,
    > MATCH(Sheet2!B2,Sheet1!B2:AN2,0)) where Sheet2!B2
    > was my list of values. Thanks again


+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1