[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

Using an IF statement to sort data

Posted on 2015-02-03
4
Medium Priority
?
69 Views
Last Modified: 2015-02-03
I am attempting to identify the minimum value occurs before the maximum value, but would like to know if there is a function that I can use, rather than using a macro.

In detail, in row 4, I find the minimum value of 2 and the maximum value of 410.  I would like to return the date (the header row) of the minimum value and the date of the maximum value IF the minimum value occurs before the maximum value.  If the maximum value occurs before, then return nothing.

I have been racking my brain with an IF statement or a combination of IF and range, but am drawing  a blank.  I have a sparkline in place to help visualize how the values fluctuate.
0
Comment
Question by:Sabealgo
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 43

Expert Comment

by:Saqib Husain, Syed
ID: 40587096
Did you intend to upload a file?
0
 

Author Comment

by:Sabealgo
ID: 40587105
I did. Sorry.  here it is.
SAMPLE.xlsx
0
 
LVL 48

Accepted Solution

by:
Wayne Taylor (webtubbs) earned 2000 total points
ID: 40587311
In row 4, use these formulas...

    =IF(MATCH(MIN(C4:V4), C4:V4, 0)<MATCH(MAX(C4:V4), C4:V4, 0), INDEX(C$2:V$2, MATCH(MIN(C4:V4), C4:V4, 0)), "")
    =IF(MATCH(MIN(C4:V4), C4:V4, 0)<MATCH(MAX(C4:V4), C4:V4, 0), INDEX(C$2:V$2, MATCH(MAX(C4:V4), C4:V4, 0)), "")

Note that if the Min or Max values occur twice, only the date for the first occurrence will be returned.
0
 

Author Closing Comment

by:Sabealgo
ID: 40587330
Thank you for your help.  This works.
0

Featured Post

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to import an Outlook PST file to Office 365 using a third party product to avoid Microsoft's Azure command line tool, saving you time.
We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
This Micro Tutorial will demonstrate in Google Sheets how to use the HYPERLINK function to create live links inside your spreadsheet.
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

656 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question