+ Reply to Thread
Results 1 to 5 of 5

Multiple of IF statements

  1. #1
    Registered User
    Join Date
    10-21-2020
    Location
    Barcelona, Spain
    MS-Off Ver
    365
    Posts
    2

    Multiple of IF statements

    hi, I am looking to do a multiple if statements to calculate a value based on shares vesting at different % in different years. For example, in year 1, 15% of your allotted shares vest, a further 20% in years 2-4 and the last 25% in the final year. I keep getting a message saying that if I am not trying to type a formula, then I must not put +/- at the start of things.

    I need to do two formulas (columns h & I). Column H gives the shares that vest only when full years have been completed. COlumn I calculates by day.

    If anyone could help me please as I have got close but cannot finish the formula to take in the five years and am going crazy

    Bradser
    Attached Files Attached Files

  2. #2
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,739

    Re: Multiple of IF statements

    column H
    =+IF(E4< 365,0,IF(AND(E4< 730,E4 > 365),G4*15%+IF(AND(E4 < 1095,E4 > 730),G4*35%,IF(AND(E4 < 1460,E4 > 1095),G4*55%,IF(AND(E4 < 1825,E4 > 1460),G4*75%,IF(E4 > 1825,G4))))))
    Why the +
    do you just have a range
    < 365 = 0
    < 730 = 15%
    < 1095 = 35%
    etc

    you dont need the AND
    the IF works left to right
    so the LESS than 365 applies and so the next IF must be > 365 ????? , so you dont need the AND
    BUT what happens IF = 365 as that has not be applied

    so you could simplify to

    =IF(E4 < 365,0,IF(E4 < 730,G4*15%,IF(E4 < 1095,G4*35%,IF(E4 < 1460,G4*55%,IF(E4 < 1825),G4*75%,IF(E4 > 1825,G4))))))
    BUT you need to sort the value of days it applies
    does 365 =0 , if so then
    =IF(E4 <= 365,0,IF(E4 < 730,G4*15%,IF(E4 < 1095,G4*35%,IF(E4 < 1460,G4*55%,IF(E4 < 1825),G4*75%,IF(E4 > 1825,G4))))))
    does 730 = 15%
    is then 730 also needs a < or =
    =IF(E4 <= 365,0,IF(E4 <= 730,G4*15%,IF(E4 <= 1095,G4*35%,IF(E4 <= 1460,G4*55%,IF(E4 <= 1825,G4*75%,G4)))))
    you dont need the
    IF(E4 > 1825,
    as IF all the other tests do not apply - then it must be > 1825
    or a negative number
    Attached Files Attached Files
    Last edited by etaf; 10-21-2020 at 12:18 PM.
    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.

  3. #3
    Registered User
    Join Date
    10-21-2020
    Location
    Barcelona, Spain
    MS-Off Ver
    365
    Posts
    2

    Re: Multiple of IF statements

    Thanks so much Etaf, this solved my problem for both columns and you explained it in a super easy way.

    I am trying to see the reputation button on the left hand side but cannot see, it let me know where it is cause I want to give kudos

  4. #4
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,739

    Re: Multiple of IF statements

    you are welcome

    * Add Reputation
    Bottom left of each post

  5. #5
    Forum Expert bebo021999's Avatar
    Join Date
    07-22-2011
    Location
    Vietnam
    MS-Off Ver
    Excel 2016
    Posts
    9,463

    Re: Multiple of IF statements

    IF solution should be neater with:

    =G4* IF(E4 <= 365,0,IF(E4 <= 730,15%,IF(E4 <= 1095,35%,IF(E4 <= 1460,55%,IF(E4 <= 1825,75%,1)))))

    And shorter with LOOKUP solution.
    Quang PT

+ 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. Combining Multiple Statements That Multiple if Statements
    By OregonMBA in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-12-2020, 06:23 PM
  2. [SOLVED] Multiple If statements with multiple then statements pulling from Index/Match commands
    By Reggie Wells in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 11-30-2017, 03:25 PM
  3. [SOLVED] Nested if statements containing multiple and statements
    By John M. in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 06-22-2014, 11:48 PM
  4. Formula with multiple IF statements and IF AND statements
    By lottidotti in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 11-14-2013, 08:03 AM
  5. Replies: 3
    Last Post: 07-25-2013, 08:25 AM
  6. Multiple nested IF statements and AND statements
    By TonyGetz in forum Excel General
    Replies: 2
    Last Post: 12-14-2010, 03:07 AM
  7. Replies: 12
    Last Post: 05-15-2009, 08:38 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