count function

Status
Not open for further replies.

omer1234

Board Regular
Joined
Nov 29, 2011
Messages
161
Given this data, how do I count how many times contamination had a "1"

Team A - = 1 time
Team D - 2 times
Team C - 1 times
Team Z - 0 times

Would be nice if the formula can ignore all the "0" or blank cells.

Thanks

***** if I were to count Wrinkles with a 1 in a cell , only Team z would have 1 entry ***********

Team DTeam CTeam ATeam DTeam CTeam Z
Column AColumn BColumn CColumn DColumn EColumn FColumn G
Wrinkles030331
Contamination111100
Holes301330
Wrap013310
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.
I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

Try this

24 02 28.xlsm
ABCDEFG
1Team DTeam CTeam ATeam DTeam CTeam Z
2Column AColumn BColumn CColumn DColumn EColumn FColumn G
3Wrinkles030331
4Contamination111100
5Holes301330
6Wrap013310
7
8ContaminationWrinkles
9Team A10
10Team C10
11Team D20
12Team Z01
Count
Cell Formulas
RangeFormula
B9:C12B9=SUMPRODUCT(($B$1:$G$1=$A9)*($A$3:$A$6=B$8)*($B$3:$G$6=1))
 
Upvote 0
I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

Try this

24 02 28.xlsm
ABCDEFG
1Team DTeam CTeam ATeam DTeam CTeam Z
2Column AColumn BColumn CColumn DColumn EColumn FColumn G
3Wrinkles030331
4Contamination111100
5Holes301330
6Wrap013310
7
8ContaminationWrinkles
9Team A10
10Team C10
11Team D20
12Team Z01
Count
Cell Formulas
RangeFormula
B9:C12B9=SUMPRODUCT(($B$1:$G$1=$A9)*($A$3:$A$6=B$8)*($B$3:$G$6=1))
I am getting #N/A error , can you verify formula please
 
Upvote 0
Could you please address the first point in my previous post?


I am getting #N/A error , can you verify formula please
I have provided my sample data with the formula showing as working. You can copy my sheet using this icon at the top left of my mini sheet and paste into cell A1 of a blank worksheet to test.

1709097827110.png


Perhaps you could provide your sample data also with XL2BB and then we could be more sure we are testing with the right data and layout. :)
 
Upvote 0
I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

Try this

24 02 28.xlsm
ABCDEFG
1Team DTeam CTeam ATeam DTeam CTeam Z
2Column AColumn BColumn CColumn DColumn EColumn FColumn G
3Wrinkles030331
4Contamination111100
5Holes301330
6Wrap013310
7
8ContaminationWrinkles
9Team A10
10Team C10
11Team D20
12Team Z01
Count
Cell Formulas
RangeFormula
B9:C12B9=SUMPRODUCT(($B$1:$G$1=$A9)*($A$3:$A$6=B$8)*($B$3:$G$6=1))
I am using office 365 & I will update my profile

Thx
 
Upvote 0
Great. That just leaves you to test my data/formulas directly and/or provide your data/layout with XL2BB


Mine is formatted a little different but I still dont understand why I am getting #N/A

=SUMPRODUCT((B7:AP7=$A2)*(A8:A58=C$1)*(B8:AP33=1))

Lamination
A-Team#N/A
Team C
D-Team
Team Z
TeamA-TeamD-TeamA-TeamD-TeamD-TeamD-TeamD-TeamD-TeamA-Team
Lamination
1​
1​
0​
0​
0​
0​
0.00​
0.00​
0.00​
Tail Seal
0​
0​
0​
0​
0​
0​
0.00​
0.00​
0.00​
Roll Start
0​
0​
0​
0​
0​
0​
0.00​
0.00​
0.00​
Contamination
0​
0​
0​
0​
0​
0​
0.00​
0.00​
0.00​
Wrinkles
1.00​
0.00​
0.00​
0.00​
0.00​
0.00​
0.00​
0.00​
0.00​
Saw Cut or Slitter
0.00​
0.00​
0.00​
0.00​
0.00​
0.00​
0.00​
0.00​
0.00​
 
Upvote 0
Mine is formatted a little different but I still dont understand why I am getting #N/A

=SUMPRODUCT((B7:AP7=$A2)*(A8:A58=C$1)*(B8:AP33=1))
Because you haven't matched your range sizes. Those two red numbers should be the same as each other.
 
Upvote 0
Duplicate to: Count function help

In future, please do not post the same question multiple times. Per Forum Rules (#12), posts of a duplicate nature will be locked or deleted.

In relation to your question here, I have closed this thread so please continue in the linked thread.
 
Upvote 0
Status
Not open for further replies.

Forum statistics

Threads
1,223,948
Messages
6,175,579
Members
452,653
Latest member
craigje92

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top