+ Reply to Thread
Results 1 to 5 of 5

Understanding Function

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    06-18-2010
    Location
    USA
    MS-Off Ver
    Excel 2016
    Posts
    546

    Understanding Function

    Hello I have a workbook that has this formula in it, but I have no idea what this formula is doing.

    Can someone explain to me what this formula does?

    =IF(COUNTIF(SortGroup1,H3)>0,0,IF(OR(D3="Jackson, Mitchell",D3="Initz, Abigail"),-1,3))

  2. #2
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,741

    Re: Understanding Function

    What's it's saying is
    If the value in H3 is found anywhere in the range "SortGroup1" then return 0 else if D3 is either "Jackson, Mitchell" or "Initz, Abigail" then return -1 & if none of that is true return 3

  3. #3
    Forum Contributor
    Join Date
    06-18-2010
    Location
    USA
    MS-Off Ver
    Excel 2016
    Posts
    546

    Re: Understanding Function

    What is SortGroup1? I don't see anything in the workbook (that's obvious) called that...

  4. #4
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.92 (24120731))
    Posts
    9,101

    Re: Understanding Function

    IF(TEST, TRUE,FALSE)
    This is a nested IF , IN THE false section
    so
    IF(TEST1 , TRUE1 , IF( TEST2, TRUE2 , FALSE))

    COUNTIF(SortGroup1,H3)>0
    So if the count in the range name sortgroup, has a value of H3 and the count is greater than 0 - its TRUE so
    do the TRUE part in this 0
    IF FALSE
    The thats another IF
    The TEST is
    OR(D3="Jackson, Mitchell",D3="Initz, Abigail")
    SO IF the cell D3 contains the WORD "Jackson, Mitchell",OR "Initz, Abigail" then TRUE so result is -1
    IF thats also FALSE
    then do the FALSE 3

    So the results in the cell will be 0, -1 OR 3
    depending on the results of the TESTs
    Wayne
    if my assistance has helped, and only if you wish to , there is an "* Add Reputation" on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  5. #5
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,936

    Re: Understanding Function

    COUNTIF(SortGroup1,H3)>0
    • look down the column labeled SortGroup1 to find a value matching whatever is in H3 and return the number of times found
    • If it is found (doesn't matter how many) then put 0 in the cell

    OR(D3="Jackson, Mitchell",D3="Initz, Abigail"
    • If H3 data is not found (i.e., COUNTIF=0), then check D3 for either Jackson, Mitchell or Initz, Abigail
    • if either is found put -1
    • otherwise the result of the formula is 3

    to find sortgroup1, click FORMULA menu on the ribbon, manage names...
    Last edited by protonLeah; 01-15-2021 at 06:35 PM.
    Ben Van Johnson

+ 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. Help understanding and editing this function
    By Oswabatista in forum Excel General
    Replies: 3
    Last Post: 10-07-2020, 03:15 AM
  2. [SOLVED] understanding MOD function
    By H28Sailor in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 10-08-2013, 08:40 AM
  3. help understanding a function
    By ds0919 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 06-03-2013, 04:13 PM
  4. Need Help using and understanding IF function
    By isixes27ce in forum Excel General
    Replies: 5
    Last Post: 11-09-2012, 04:16 PM
  5. Understanding an IF Function
    By rcrhymes123 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 07-13-2011, 01:31 PM
  6. Understanding the Sumproduct function
    By Blake 7 in forum Excel General
    Replies: 2
    Last Post: 01-31-2011, 12:11 PM
  7. understanding IF function
    By beets in forum Excel - New Users/Basics
    Replies: 2
    Last Post: 03-18-2008, 11:29 AM

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