+ Reply to Thread
Results 1 to 4 of 4

formula needed to assign a number based on value and then add those numbers

  1. #1
    Registered User
    Join Date
    05-12-2021
    Location
    Wisconsin
    MS-Off Ver
    2016
    Posts
    2

    formula needed to assign a number based on value and then add those numbers

    Hello, I have a fairly complex spreadsheet going on with a ton of data that reflects on other data. Have all my formula/functions figured out except one, and it's beginning to become a headache trying to figure this one out lol.

    Exactly from my spreadsheet, cell AH4 contains 16%, I need a formula that will assign 16% and lower the number 3, 17% the number 2, and then 18% or greater the number 1. That's the easy part...
    Cell AV4 contains 15%, I need it to be looking to AH4's value of 16%, like AH4, I need AHV to assign 16% and less the number 3, 17% the number 2, and 18% or greater the number 1... and then the difficult part (to me anyways)...
    Cells BJ4 & BK4 each contain 13% (mirrors to each other), I need the BJ4 to weigh against AH4, but BK4 to weigh against AV4, and assign the numbers 1, 2, and 3 to their results... but it's not over there. There's one final group at CD4, CE4, and CF4, the values at this group is 10%, but also changes in intervals of 5. so CD4 would weigh against AH4, CE4 would weigh against AV4, and CF4 would weigh against the percentage at BJ4/BK4, and then assign 1, 2, or 3 to their values. Then after all that's done, I need it to add all those 1's, 2's, and 3's and show the added amount in cell DF4. If they all get 3's it'd add up to 21, if they all get 1's it'd add up to 7, and then there's the in between values.

    Been racking my brain with a bunch of methods found via google search that don't end up working. It's a lot of criteria, and probably going to be a hefty formula to make it work, but if anyone has any ideas, I'm all ears... which are currently smoking from the gears spinning lol...

    Thanks in advance!
    Attached Files Attached Files
    Last edited by pwick; 05-12-2021 at 01:53 AM.

  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
    52,933

    Re: formula needed to assign a number based on value and then add those numbers

    To best describe or illustrate your problem you would be better off attaching a dummy workbook. The workbook should contain the same structure and some dummy data of the same type as the type you have in your real workbook - so, if a cell contains numbers & letters in this format abc-123 then that should be reflected in the dummy workbook.

    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.
    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
    05-12-2021
    Location
    Wisconsin
    MS-Off Ver
    2016
    Posts
    2

    Re: formula needed to assign a number based on value and then add those numbers

    Thank you for the reply,

    I've just attached a "dummy" worksheet... Essentially what it's showing is in the first part each cell following is of lesser value than the one it's being weighed against, resulting in that cell getting a "3" value. Which added up would sum to 21. In the second part the values go back and forth and would add up to 17. Need a formula that will do the adding automatically to reduce the need of Tylenol lol

  4. #4
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,558

    Re: formula needed to assign a number based on value and then add those numbers

    Hello pwick and Welcome to Excel Forum.
    In the file attached to post #1 cell H20 contains "3" yet the value in H19 is 25%. According to the description in post #1 I would assume that since the value of H19 is greater than 18% it would have a value of "1", so I am confused at the outset.
    I feel that to understand what is happening we would need to see the following type of explanation:
    Cell H19 is assigned a value of "3" because ...
    Cell K19 is assigned a value of "3" because ...
    .
    .
    .
    Cell T19 is assigned a value of "1" because ...
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

+ 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. Formula needed based off number of fields
    By lemonap618 in forum Excel General
    Replies: 1
    Last Post: 09-16-2020, 03:04 PM
  2. Replies: 2
    Last Post: 08-12-2015, 01:01 AM
  3. [SOLVED] Formula needed to get Date in text based on numbers
    By caabdul in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-25-2014, 08:40 PM
  4. [SOLVED] Formula needed to identify number within a range of numbers
    By easglos in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-26-2012, 09:26 AM
  5. [SOLVED] Formula needed based on cumulative numbers
    By ramblin in forum Excel General
    Replies: 3
    Last Post: 06-22-2012, 05:53 AM
  6. Replies: 3
    Last Post: 04-03-2012, 02:52 PM
  7. Replies: 5
    Last Post: 08-06-2009, 05:17 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