Counting with conditions based on another range

S

stephanie

HI. I've tried several different ways now to the experts :)

I have two rows of data:
Emp Lvl Rating
1 4
2 3
2 2
1 4
1 2
2 3

I need to count How many emp lvl 2's with rating 2 = 1

what is the formula for this?
 
D

dmkAlex

HI.  I've tried several different ways now to the experts :)

I have two rows of data:
Emp Lvl           Rating
1                    4
2                    3
2                    2
1                    4
1                    2
2                    3

I need to count How many emp lvl 2's with rating 2 = 1

what is the formula for this?

I use an arrary formula:

={SUM(IF(A2:A7=1,1,0)*IF(B2:B7=2,1,0))}

Create an array formula

When you enter an array formula (array formula: A formula that
performs multiple calculations on one or more sets of values, and then
returns either a single result or multiple results. Array formulas are
enclosed between braces { } and are entered by pressing CTRL+SHIFT
+ENTER.), Microsoft Excel automatically inserts the formula between
{ } (braces).
 
S

stephanie

Thanks I understand the formula but what if I just wanted the N - how many
level 2 responded to the question or in this case received a rating
(regardess of the rating score?)?

-S
 
P

Pete_UK

Try this:

=COUNTIF(A:A,2)

or perhaps this:

=SUMPRODUCT((A1:A100=2)*(B1:B100<>""))

Hope this helps.

Pete
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top