PC Review


Reply
Thread Tools Rate Thread

Counting using multiple criteria

 
 
Shawn
Guest
Posts: n/a
 
      22nd Oct 2008
I need an array formula that will do the following. Count (not sum) the
number of cells in column C that are above the value of 0 if the adjacent
cells in Column A are equal to a value of 1.



--
Thanks
Shawn
 
Reply With Quote
 
 
 
 
TomPl
Guest
Posts: n/a
 
      22nd Oct 2008
=sumproduct(--(A1:A65536=1),--(C1:C65536>0))

"Shawn" wrote:

> I need an array formula that will do the following. Count (not sum) the
> number of cells in column C that are above the value of 0 if the adjacent
> cells in Column A are equal to a value of 1.
>
>
>
> --
> Thanks
> Shawn

 
Reply With Quote
 
Shawn
Guest
Posts: n/a
 
      22nd Oct 2008
What is the significance of the "--"s? Also, what if I want to change the
formula as follows?
=sumproduct(--(A1:A65536=B1),--(C1:C65536>0)) as opposed to
=sumproduct(--(A1:A65536=1),--(C1:C65536>0))


--
Thanks
Shawn


"TomPl" wrote:

> =sumproduct(--(A1:A65536=1),--(C1:C65536>0))
>
> "Shawn" wrote:
>
> > I need an array formula that will do the following. Count (not sum) the
> > number of cells in column C that are above the value of 0 if the adjacent
> > cells in Column A are equal to a value of 1.
> >
> >
> >
> > --
> > Thanks
> > Shawn

 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      23rd Oct 2008
First, you can't use the entire column in xl2003 and older. So adjust your
ranges accordingly.

=sumproduct() likes to work with numbers. The -- stuff changes trues and falses
to 1's and 0's.

Bob Phillips explains =sumproduct() in much more detail here:
http://www.xldynamic.com/source/xld.SUMPRODUCT.html

And J.E. McGimpsey has some notes at:
http://mcgimpsey.com/excel/formulae/doubleneg.html

Shawn wrote:
>
> What is the significance of the "--"s? Also, what if I want to change the
> formula as follows?
> =sumproduct(--(A1:A65536=B1),--(C1:C65536>0)) as opposed to
> =sumproduct(--(A1:A65536=1),--(C1:C65536>0))
>
> --
> Thanks
> Shawn
>
> "TomPl" wrote:
>
> > =sumproduct(--(A1:A65536=1),--(C1:C65536>0))
> >
> > "Shawn" wrote:
> >
> > > I need an array formula that will do the following. Count (not sum) the
> > > number of cells in column C that are above the value of 0 if the adjacent
> > > cells in Column A are equal to a value of 1.
> > >
> > >
> > >
> > > --
> > > Thanks
> > > Shawn


--

Dave Peterson
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Counting multiple criteria GillW Microsoft Excel Discussion 4 28th Mar 2006 03:35 PM
counting using multiple criteria =?Utf-8?B?U3ludGFYIFRlcnJvUg==?= Microsoft Excel Misc 3 25th Aug 2005 01:47 PM
Counting Cells with multiple criteria.One criteria supporting wild =?Utf-8?B?QXpoYXIgQXJhaW4=?= Microsoft Excel Worksheet Functions 1 12th Jan 2005 08:33 AM
Counting Cells with multiple criteria.One criteria supporting wild =?Utf-8?B?QXpoYXIgU2FsZWVt?= Microsoft Excel Worksheet Functions 0 12th Jan 2005 07:51 AM
Counting with multiple criteria Thuy Microsoft Excel Worksheet Functions 4 3rd Jul 2004 01:23 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 12:17 PM.