+ Reply to Thread
Results 1 to 9 of 9

Anyone know how I can add the row number to a MIN function output?

  1. #1
    Registered User
    Join Date
    03-17-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    5

    Question Anyone know how I can add the row number to a MIN function output?

    Hello,

    So I'm trying to calculate breakeven for a capital budgeting template and I've got it to display the right number from the set of values using the MIN function, however I need to add the nper number or row number. Anyone know how to add the corresponding row number to an output like this?

    Breakeven formula: =MINABS(L3:L8)

    Breakeven numbers are in column L, row numbers are in column A.

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Anyone know how I can add the row number to a MIN function output?

    You mean you want to show the row number of the value returned by MINABS? What do you mean "row numbers are in column A"? Are you talking about row numbers that are different than Excel row numbers? Based on your description, the row number is given by this formula, assuming your breakeven formula above is in cell M1, and you need the value in column A that is found in the same row as the value returned by MINABS:

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    03-17-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Anyone know how I can add the row number to a MIN function output?

    Um sort of, but my row numbers are slightly different than the Excel row numbers because they're the number of cash flows. Hopefully this pic can help illustrate what I'm trying to do.
    Excelp.jpg

    Since .333 is in the row Cash Flow 3, I want to add the 3, but have it automated so no matter which row the breakeven is in it will add the corresponding row/cash flow number.
    Last edited by DiagonalDog; 03-17-2014 at 01:23 PM. Reason: Further explanation

  4. #4
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Anyone know how I can add the row number to a MIN function output?

    We need to start over again. There are two problems.

    First, I need you to clarify what result you are looking for. What do you mean by "add the corresponding row number"? Using your screenshot as an example, what output do you want to see? 3.333? That's what "add" means but somehow it doesn't seem to make sense in this context.

    Second, you need to describe what MINABS does. It is not a built-in Excel function. Your formula uses a range in column L but you are pointing us to a result that comes from column F.

    Also, an image attachment has very little value. Just attach the Excel file. It's easier than taking a screenshot first and then attaching that. This allows us to see and experiment with your data, layout, formulas, code, and possibly attach a file with a completed solution.

  5. #5
    Registered User
    Join Date
    03-17-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Anyone know how I can add the row number to a MIN function output?

    You're correct, I'm sorry. This is my first time posting here so I'm not sure how much people are generally familiar with and what is expected of me.

    1. Yes, I'd like to see 3.33 for that case, as the output is the number of cash flows until breakeven is reached. Since the breakeven number (.333) in this case can be in any row in the range, I need a function that can find the cash flow number it corresponds with and add them together.

    2. MINABS does what those two functions do separately, just as one function. It converts the numbers in the range to the Absolute Values and then finds the minimum. Definitely should've clarified this as I had to "hack" Excel to do it (followed a simple online tutorial)

    3. Didn't realize it was an option, though in retrospect it should've been obvious. I can definitely do so.

    The problem in question is on Sheet 6: Book1.xlsx
    Last edited by DiagonalDog; 03-17-2014 at 04:41 PM. Reason: Moved attachment link

  6. #6
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Anyone know how I can add the row number to a MIN function output?

    The formula for MINABS that you showed in your first post is in cell O11, but in your screenshot you put the circle around O10. So either the screenshot is annotated wrong, or you plugged the wrong formula into your first post.

    Based on your first post and ignoring the screenshot, you want this formula:

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    If, on the other hand, I should look at your screenshot and ignore the post, then you want

    Formula: copy to clipboard
    Please Login or Register  to view this content.


    Hopefully one of those is what you need

  7. #7
    Registered User
    Join Date
    03-17-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Anyone know how I can add the row number to a MIN function output?

    Hmmm Both of these just gave me #NAME errors :/ Might just have to do some fiddling with the references or something. But I have actual homework I need to do first. Thank you!

  8. #8
    Registered User
    Join Date
    03-17-2014
    Location
    United States
    MS-Off Ver
    Excel 2010
    Posts
    5

    Re: Anyone know how I can add the row number to a MIN function output?

    Just tried it again and it worked perfectly! Thank you!

  9. #9
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Anyone know how I can add the row number to a MIN function output?

    You're welcome! I got a NAME error also but that is because I don't have a function called MINABS defined. Your file doesn't have macros so I assume you must have built an add-in.

    If your question has been answered please mark your thread as "Solved" so that members will know by looking at the thread title that your problem is solved.

    Go to the menu immediately above your first post to the thread and click on Thread Tools. From the dropdown menu select "Mark this thread as solved..."

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Number Output
    By wchillman in forum Excel General
    Replies: 3
    Last Post: 08-09-2013, 06:42 AM
  2. [SOLVED] Output number as a number, not text
    By Ocean Zhang in forum Excel General
    Replies: 2
    Last Post: 08-07-2013, 10:23 PM
  3. create an inline function that will output only a certain number of results.
    By blackspiral in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-10-2013, 10:06 AM
  4. [SOLVED] Combined AND function not reading output of the function of another cell
    By Duoae in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 10-19-2012, 09:22 AM
  5. Replies: 7
    Last Post: 12-18-2008, 07:34 PM

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