ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   conditions in "countif" (https://www.excelbanter.com/excel-discussion-misc-queries/68735-conditions-countif.html)

Clash

conditions in "countif"
 

Hi all,

I know that I have asked this question before, but I got it a bit
wrong.

What I am trying to count is criteria from two different columns, lets
say column F and column H.

i.e. F, I will count all of the females and H I will count all of the
Blondes. But what I am trying to count is all of the Blonde Females,
therefore using being able to seperate them from the Brunette Females,
Redhead Females, etc.

cheers

Clash:confused:


--
Clash
------------------------------------------------------------------------
Clash's Profile: http://www.excelforum.com/member.php...o&userid=18951
View this thread: http://www.excelforum.com/showthread...hreadid=507192


Bob Phillips

conditions in "countif"
 
I thought that might be the case, and thought about including it, but you
seemed so definite <G

=SUMPRODUCY(--(F2:F200="blonde"),--(H2:H200="blonde"))

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Clash" wrote in message
...

Hi all,

I know that I have asked this question before, but I got it a bit
wrong.

What I am trying to count is criteria from two different columns, lets
say column F and column H.

i.e. F, I will count all of the females and H I will count all of the
Blondes. But what I am trying to count is all of the Blonde Females,
therefore using being able to seperate them from the Brunette Females,
Redhead Females, etc.

cheers

Clash:confused:


--
Clash
------------------------------------------------------------------------
Clash's Profile:

http://www.excelforum.com/member.php...o&userid=18951
View this thread: http://www.excelforum.com/showthread...hreadid=507192




bob777

conditions in "countif"
 

I find using the sumproduct worksheet function is ideal for this type of
request.
=sumproduct(($a$1:$a$100="blonde")*($b$1:$b$100="f emale")*1)

the *1 at the end might not be needed


--
bob777
------------------------------------------------------------------------
bob777's Profile: http://www.excelforum.com/member.php...o&userid=28504
View this thread: http://www.excelforum.com/showthread...hreadid=507192


Gary''s Student

conditions in "countif"
 
You can reduce two (or many) criteria to a single criterium:


In an un-used cell enter:
=F1 & H1 and copy down

Then the criterium would be BlondeFemale
--
Gary's Student


"Clash" wrote:


Hi all,

I know that I have asked this question before, but I got it a bit
wrong.

What I am trying to count is criteria from two different columns, lets
say column F and column H.

i.e. F, I will count all of the females and H I will count all of the
Blondes. But what I am trying to count is all of the Blonde Females,
therefore using being able to seperate them from the Brunette Females,
Redhead Females, etc.

cheers

Clash:confused:


--
Clash
------------------------------------------------------------------------
Clash's Profile: http://www.excelforum.com/member.php...o&userid=18951
View this thread: http://www.excelforum.com/showthread...hreadid=507192



Bob Phillips

conditions in "countif"
 
That should be SUMPRODUCT of course.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Bob Phillips" wrote in message
...
I thought that might be the case, and thought about including it, but you
seemed so definite <G

=SUMPRODUCY(--(F2:F200="blonde"),--(H2:H200="blonde"))

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"Clash" wrote in

message
...

Hi all,

I know that I have asked this question before, but I got it a bit
wrong.

What I am trying to count is criteria from two different columns, lets
say column F and column H.

i.e. F, I will count all of the females and H I will count all of the
Blondes. But what I am trying to count is all of the Blonde Females,
therefore using being able to seperate them from the Brunette Females,
Redhead Females, etc.

cheers

Clash:confused:


--
Clash
------------------------------------------------------------------------
Clash's Profile:

http://www.excelforum.com/member.php...o&userid=18951
View this thread:

http://www.excelforum.com/showthread...hreadid=507192






Bob Phillips

conditions in "countif"
 
It is not, the * does all the coercion needed.

--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"bob777" wrote in
message ...

I find using the sumproduct worksheet function is ideal for this type of
request.
=sumproduct(($a$1:$a$100="blonde")*($b$1:$b$100="f emale")*1)

the *1 at the end might not be needed


--
bob777
------------------------------------------------------------------------
bob777's Profile:

http://www.excelforum.com/member.php...o&userid=28504
View this thread: http://www.excelforum.com/showthread...hreadid=507192




Clash

conditions in "countif"
 

Thanks for all your help.

and just to let you know how I worked it out, I used this "array
formula".

=sum((F2:F200="female")*(H2:H200="blonde")) and then pressed
Ctl/Shift/enter.

and it worked.

Once again thanks for your help.:)


--
Clash
------------------------------------------------------------------------
Clash's Profile: http://www.excelforum.com/member.php...o&userid=18951
View this thread: http://www.excelforum.com/showthread...hreadid=507192



All times are GMT +1. The time now is 11:58 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com