+ Reply to Thread
Results 1 to 6 of 6

Min and Max functions with a restriction on values

Hybrid View

  1. #1
    Registered User
    Join Date
    12-19-2012
    Location
    Melbourne, Australia
    MS-Off Ver
    Excel 2010
    Posts
    18

    Min and Max functions with a restriction on values

    Hi guys,

    I am working with some data and want to pick out the Mix and Max values subject to the condition that the min values are greater then 10 and max values are less than 80, this is to remove outliers from the data. Any one know what function to add to my min or max function to achieve this?

    Thanks Guys!

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Min and Max functions with a restriction on values

    You dont give any ranges, so adjust as needed....

    =MAX(IF(A1:A10<80,B1:B10,0))
    =MIN(IF(A1:A10>10,B1:B10,0))

    These are array formulas
    ...confirmed by pressing CTRL-SHIFT-ENTER to activate the array. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL-SHIFT-ENTER you will get an error or a clearly incorrect answer. Press F2 on that cell and try again.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    12-19-2012
    Location
    Melbourne, Australia
    MS-Off Ver
    Excel 2010
    Posts
    18

    Re: Min and Max functions with a restriction on values

    Thanks FDibbins,

    It have not quite fixed the problem, due to me not being specific enough, sorry! I have 10 columns of data A1:A10 .... J1:J10 and I want to pick out the min and max for each column. Even if the min or max in the column is less then 10 or greater then 80 I would like it to report the min that is above 10 something like

    8 It wont report the 8 in the column
    12
    18
    80
    76
    150
    14
    min 12

    I'm not even sure it is possible, and thanks very much for your help so far!!!!

  4. #4
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Min and Max functions with a restriction on values

    i would suggest you upload a sample work book, (all sensitive data removed), showing what data you are working with, a few examples of what your expected outcome is, and how you arrived at that
    To attach a file to your post,
    click advanced (next to quick post),
    scroll down until you see "manage file",
    click that and select "add files" (top right corner).
    click "select files" find your file, click "open" click "upload" click 'done" bottom right. click "submit reply"

    Once the upload is completed the file name will appear below the input boxes in this window.
    You can then close the window to return to the new post screen.

  5. #5
    Forum Expert
    Join Date
    07-20-2011
    Location
    Mysore, India.
    MS-Off Ver
    Excel 2019
    Posts
    8,710

    Re: Min and Max functions with a restriction on values

    Pl see attached file.
    Attached Files Attached Files

  6. #6
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    53,048

    Re: Min and Max functions with a restriction on values

    OK I looked at what you uploaded and you have used the formula I suggested, what would you have expected the answers to be?

+ 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