+ Reply to Thread
Results 1 to 2 of 2

Deciphering a formula

  1. #1
    Registered User
    Join Date
    10-26-2010
    Location
    Richmond, Virginia
    MS-Off Ver
    Excel 2007
    Posts
    26

    Question Deciphering a formula

    Can someone tell me what this formula is doing?

    =CHOOSE(SIGN((ROWS(A$2:A15)-COLUMNS($B15:B15)))+2,"",1,PEARSON(INDEX(Sheet1!$63:$314,0,MATCH(B$1,Sheet1!$17:$17,0)+1),INDEX(Sheet1!$63:$314,0,MATCH($A15,Sheet1!$17:$17,0)+1)))

    Thank you,
    MofB
    Last edited by MarginofBuffett; 11-15-2010 at 05:07 PM. Reason: [SOLVED]

  2. #2
    Forum Guru DonkeyOte's Avatar
    Join Date
    10-22-2008
    Location
    Northumberland, UK
    MS-Off Ver
    O365
    Posts
    21,531

    Re: Deciphering a formula

    context: http://www.excelforum.com/excel-gene...on-matrix.html

    The ROWS-COLUMNS result of every given cell within the matrix determines whether or not a calculation needs to be performed in the first instance - and - if so - which calculation...

    If Rows < Columns [<0] then no calculation
    If Rows = Columns [=0] then result will be 1 (no calc needed per se)
    If Rows > Columns [>0] then need to perform the PEARSON calculation

    We use CHOOSE in conjunction with SIGN to action the above.

    We know the SIGN of our ROWS-COLUMNS calculation will be either -1 (negative), 0 (0) or 1 (positive)

    Obviously we can't use negative values for the index_num value in our CHOOSE calculation so we add 2 to the SIGN result such that the values become 1, 2 & 3 respectively.

    The appropriate function is then actioned based on the now revised index_num, ie 1 returns Null, 2 returns 1 and 3 returns the PEARSON calc.

    The PEARSON calculation in itself uses INDEX with MATCH twice over to create the appropriate array ranges.
    In both cases all rows are returned from rows $63:$314 - the column used for each array is determined by Matching B$1 / $A15 in row 17 respectively.

+ 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