+ Reply to Thread
Results 1 to 2 of 2

How can a range be equal a single cell?

  1. #1
    Registered User
    Join Date
    06-24-2014
    Location
    Germany
    MS-Off Ver
    2010
    Posts
    1

    How can a range be equal a single cell?

    Hi everyone,

    I am reading this fomular and cannot understand it.

    =SUMPRODUCT($Q$13:$Q$309,($P$13:$P$309=$D20)*1,($O$13:$O$309=H$8)*1)

    Basically each input should be a matrix and the first one really is. However the other two are not and look unfamiliar to me.

    Could you please explain it to me? Thank you very much

  2. #2
    Forum Guru Jonmo1's Avatar
    Join Date
    03-08-2013
    Location
    Bryan, TX
    MS-Off Ver
    Excel 2010
    Posts
    9,763

    Re: How can a range be equal a single cell?

    They are creating a range (or array actually) of TRUE/FALSE results based on the expression.

    ($P$13:$P$309=$D20)*1

    It reads it one cell at a time (P13 then P14 then P15 etc..)
    Is the value in P13 = D20, true or false?
    Is the value in P14 = D20, true or false?

    The results of those true/false questions are stored in an array
    {true,true,false,false,true,false,etc...}*1
    Then again, each true/false is multiplied by 1
    When doing a math operation like + - / * on a True/False value
    True = 1, FALSE = 0
    So it becomes
    {1,1,0,0,1,0,etc..}


    Hope that helps.

+ 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. [SOLVED] A range value is equal to a cell value but be able to change
    By tantcu in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 11-22-2013, 07:41 PM
  2. Sum cells in a range based between two equal cell values in another range
    By sshone1 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-09-2013, 08:12 AM
  3. [SOLVED] Set single cell equal to merged cell
    By VBA FTW in forum Excel General
    Replies: 3
    Last Post: 11-27-2012, 01:52 PM
  4. Make a Date variable equal a single-cell array formula
    By Shamala in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 03-07-2012, 06:29 PM
  5. How to make a single number equal a dollar amount in next cell?
    By mrphotoguy1 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 12-05-2010, 06:11 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