+ Reply to Thread
Results 1 to 3 of 3

switching < > operator breaks array formula

  1. #1
    Registered User
    Join Date
    02-26-2011
    Location
    Wellington, New Zealand
    MS-Off Ver
    Office 2010
    Posts
    2

    switching < > operator breaks array formula

    Hi all

    I feel like this is going to turn out to be something completely stupid and obvious so apologies in advance but:

    I have a formula to calculate the median value of an array, based on a number in a reference column. Basically I need to calculate the median for all of the cells with a reference number less than 7, and then all of those with a number greater than (equal to 7 is not used). The formula for the 'greater than' range works fine, but that for the 'less than' returns an N/A error, despite the two forumlae being identical in every way except for the < > symbol.

    Here is the formula in question:

    WORKS:

    {=MEDIAN(IF('Complaints Reconciliation'!$A$2:$A$1006>7,IF('Complaints Reconciliation'!$M$2:$M$1000<>0,'Complaints Reconciliation'!$M$2:$M$1000,""),""))}

    DOESN'T WORK:

    {=MEDIAN(IF('Complaints Reconciliation'!$A$2:$A$1006<7,IF('Complaints Reconciliation'!$M$2:$M$1000<>0,'Complaints Reconciliation'!$M$2:$M$1000,""),""))}

    Column A:A contains numbers from 1-6 and 8 - 11, column M:M contains numbers from 1 to about 400.

    Any ideas?

  2. #2
    Valued Forum Contributor
    Join Date
    08-23-2009
    Location
    Hampshire, UK
    MS-Off Ver
    Excel 2003, Excel 2007
    Posts
    328

    Re: switching < > operator breaks array formula

    Your arrays are not the same size. Change $A$1006 to $A$1000 and both formulas should work.

  3. #3
    Registered User
    Join Date
    02-26-2011
    Location
    Wellington, New Zealand
    MS-Off Ver
    Office 2010
    Posts
    2

    Re: switching < > operator breaks array formula

    Ah, like I said, something obvious. Thanks a bunch.

    Still a bit mystified as to why one worked and the other didn't though.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

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