+ Reply to Thread
Results 1 to 8 of 8

Sample Function Formulas

  1. #1
    Registered User
    Join Date
    12-03-2008
    Location
    The Swamp
    MS-Off Ver
    2000 Pro
    Posts
    75

    Sample Function Formulas

    First, I want to say Thank You again to everybody for all the help & patience. Is there a source somewhere with sample formulas? The formula wizard is only helpful for single functions, not if I want to combine & I may be dense, but I just haven't gotten the hang of building multiple functions yet, especially when it comes to knowing when to add zeros & ones, for the index & match functions, as an example.

    I got some great help on indexing a range from another spreadsheet, but when I tried to use it again on a different range & copied & pasted and changed the ranges, I get #REF!, which I know means I screwed something up, I'm just not sure what & I don't know what the 1's & 0's mean.

    =INDEX(RiskLevel,MATCH(1,INDEX(FREQUENCY(E5,RiskScore),0),0))

    Thanks once again. If any of the guru's need help with their golf game, let me know & I'm happy to reciprocate!!!!!
    Last edited by Georgia Golfer; 12-09-2008 at 11:08 AM.

  2. #2
    Valued Forum Contributor rwgrietveld's Avatar
    Join Date
    09-02-2008
    Location
    Netherlands
    MS-Off Ver
    XL 2007 / XL 2010
    Posts
    1,671
    Is there a source somewhere with sample formulas
    Never what you quite need. This forum has solved many questions and had given many sample formula's. Use them for inspiration and if you cannot come to the correct result, We're here to help.

    not if I want to combine & I may be dense, but I just haven't gotten the hang of building multiple functions yet, especially when it comes to knowing when to add zeros & ones, for the index & match functions, as an example.
    Use Evaluate function for these type of functions. As a matter a fact: MAKE it a desktop icon!

    To help you out with this function I need to know the following:
    Where are RiskLevel and RiskScore referring to. Look at the defined names and tell us their range.
    Last edited by rwgrietveld; 12-09-2008 at 10:34 AM.
    Looking for great solutions but hate waiting?
    Seach this Forum through Google

    www.Google.com
    (e.g. +multiple +IF site:excelforum.com/excel-general/ )

    www.Google.com
    (e.g. +fill +combobox site:excelforum.com/excel-programming/ )

    Ave,
    Ricardo

  3. #3
    Registered User
    Join Date
    12-08-2008
    Location
    NYC
    MS-Off Ver
    2003 & XP
    Posts
    43
    i do not know of an index of sample formulas but..... if you write the outer forluma first without the variable and get it to work then simply replace the variable with another functio. It also may help to get the inner function working on its own then it is simply a F2, cut and paste over the hardcoded "variable" in the outer function.

    Step 1:
    vlookup(a12,c1:f25,1,0)

    Step 2:
    match(c6,g36:h45)

    Step 3:
    vlookup(a12,c1:f25,match(c6,g36:h45),0)


    the formula means nothing just wanted to show you the steps....

    figure out the outer then figure out how you want to determine the "1" and then just replace it. As you get more comfortable with the "coding" you will be able to do it in your head.

  4. #4
    Registered User
    Join Date
    12-03-2008
    Location
    The Swamp
    MS-Off Ver
    2000 Pro
    Posts
    75
    Quote Originally Posted by rwgrietveld View Post
    To help you out with this function I need to know the following:
    Where are RiskLevel and RiskScore referring to. Look at the defined names and tell us their range.
    RiskLevel is C12:C15 -- Low, Medium, High, & High+.

    RiskScore is the scoring floor for each level, B12:B15 -- 0, 20, 75, 125.

    E5 is the actual score for the subject account, which is pulled from another worksheet that calculates the totals for 28 different risk catagories depending on the answers from dependent drop downs from the 1st page that the CSR's will complete at account opening.

  5. #5
    Forum Expert Ron Coderre's Avatar
    Join Date
    03-22-2005
    Location
    Boston, Massachusetts
    MS-Off Ver
    2013, 2016, O365
    Posts
    6,996

    Sample Function Formulas

    1) Relevant formula samples are generally unavailable. The best approach
    is usually to play with the formula using a small sample of values where
    you know what the end result should be. Then vary the values and/or
    the function parameters and note how those changes vary the returned values.

    2) The #REF! error occurs when the referenced coordinates do not exist.
    Example:
    =INDEX(A:A,1,2)
    That formula is referencing the first cell in the second column of col_A.
    There is no second column of Col_A. The formula returns #REF!

    3) RE: =INDEX(RiskLevel,MATCH(1,INDEX(FREQUENCY(E5,RiskScore),0),0))
    Assumptions:
    RislLevel is a single column list.
    RiskScore can be a vertical or horizontal list.
    E5 contains a valid RiskScore.

    This section: FREQUENCY(E5,RiskScore)
    returns an array of RiskScore bins...eg {0,0,1,0}
    where the 1 occurs in the bin related to the E5 value.

    Typically, the formula would need to be ARRAY ENTERED, by pressing
    CTRL+SHIFT+ENTER (instead of just ENTER), to convert the FREQUENCY
    function into an array that the MATCH function can use.

    However, when the INDEX function refers to a single column or single row
    series, or a function that returns a series of values) and the second
    paramater is a 0...it converts that series to an array.
    So, CTRL+SHIFT+ENTER would not be necessary.

    The 3rd parameter of the MATCH function is typically 0 or 1.
    0 indicates that an exact match is required and the list can be in any order.
    Example:
    =MATCH(5,{2,4,6,8},0) returns #NA...5 is NOT in that list.
    =MATCH(5,{2,4,5,8},0) returns 3...5 is the 3rd item in that list.

    1 indicates that an approximate match is acceptable
    (the list must be in ascending order).
    Example: =MATCH(5,{2,4,6,8},1) returns 2...4 (the 2nd value) is the highest
    value that is less than or equal to 5.

    I hope that helps.
    Ron
    Former Microsoft MVP - Excel (2006 - 2015)
    Click here to see the Forum Rules

  6. #6
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464
    Hi,

    There are several excellent Excel help sites, a couple of which I mention below, however by their very nature they may contain more complex formulae than you need for a learning session. I find the best way is just dive in and do it. A technique I use a lot is to create a simple Function like say =INDEX(Range,row,column), then in another cell use say an =MATCH function which uses a column from the Range you used in the INDEX() function. e.g
    Please Login or Register  to view this content.
    This will return a row number. Now copy this formula and substitute it for the row reference in the INDEX() function. Do this with other constants and you'll gradually build your own complex formulae. The advantage of this method is that you can test each individual bit first, rather than simply typing the whole thing at one go.

    The difference between the False, True (0,1) elements in functions like =MATCH() or =VLOOKUP() is the value they return where there is more than one occurrence of that value. In a sorted list False will always return a reference to the first occurrence and True will return the last.


    http://www.xldynamic.com/source/xld.html
    http://www.contextures.com/tiptech.html
    http://www.cpearson.com/excel/links.htm

    HTH

  7. #7
    Registered User
    Join Date
    12-03-2008
    Location
    The Swamp
    MS-Off Ver
    2000 Pro
    Posts
    75
    Can't thank you guys enough. I've been playing around with it, swearing at it, & have threatened it. All it took was adding a (>) sign to the value for High+.

    I am printing out this thread for reference, Thanks so much. BTW, RW, what did you mean by "Use Evaluate function for these type of functions. As a matter a fact: MAKE it a desktop icon!". I'm using Windows 2000....I know, welcome to 2008, right? There are a few people using Vista & I have petitioned to get at least a better version of Excel (especially after I got another error log generated message & lost 2 hours of work last night)....That prompted most of the swearing and threatening!!

  8. #8
    Valued Forum Contributor rwgrietveld's Avatar
    Join Date
    09-02-2008
    Location
    Netherlands
    MS-Off Ver
    XL 2007 / XL 2010
    Posts
    1,671
    Basically you would like to convert the value 0-120 into a catagory Low
    Medium, High, High+. A simple If would do the trick
    Please Login or Register  to view this content.

+ 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