ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Counting Textual Answers (https://www.excelbanter.com/excel-worksheet-functions/28232-counting-textual-answers.html)

Lowkey

Counting Textual Answers
 
I want to Count and Total the results of a string of Text cells where Yes=1
and No=0. How do I establish the parameters for Yes and No to equal a numeric
result and then Total the result without creating a Macro? The text answer
needs to be visible: it is the result of a Yes/No choice.

Andy B

Hi
Alongside the Y/N column use a helper column containing:
=IF(A2="Yes",1,0)
You can then use this column for your total.

Andy.

"Lowkey" wrote in message
...
I want to Count and Total the results of a string of Text cells where Yes=1
and No=0. How do I establish the parameters for Yes and No to equal a
numeric
result and then Total the result without creating a Macro? The text answer
needs to be visible: it is the result of a Yes/No choice.




Bob Phillips

Do the count and total in one step

=COUNTIF(A:A,"Yes")

=COUNTA(A:A)-COUNTIF(A:A,"Yes")

--
HTH

Bob Phillips

"Andy B" wrote in message
...
Hi
Alongside the Y/N column use a helper column containing:
=IF(A2="Yes",1,0)
You can then use this column for your total.

Andy.

"Lowkey" wrote in message
...
I want to Count and Total the results of a string of Text cells where

Yes=1
and No=0. How do I establish the parameters for Yes and No to equal a
numeric
result and then Total the result without creating a Macro? The text

answer
needs to be visible: it is the result of a Yes/No choice.






Peo Sjoblom

Assumin the Yes and No are in separate cells like if the were in B1:B200 and
you want to count Yes

=COUNTIF(B1:B200,"Yes")

since you only want 1 for Yes you can just count them and the result should
be OK


Regards,

Peo Sjoblom

"Lowkey" wrote:

I want to Count and Total the results of a string of Text cells where Yes=1
and No=0. How do I establish the parameters for Yes and No to equal a numeric
result and then Total the result without creating a Macro? The text answer
needs to be visible: it is the result of a Yes/No choice.


Lowkey

Both Andy's and Peo's suggestions work, but I like Peo's better because I
don't have to create a dummy column and hide it.

"Peo Sjoblom" wrote:

Assumin the Yes and No are in separate cells like if the were in B1:B200 and
you want to count Yes

=COUNTIF(B1:B200,"Yes")

since you only want 1 for Yes you can just count them and the result should
be OK


Regards,

Peo Sjoblom

"Lowkey" wrote:

I want to Count and Total the results of a string of Text cells where Yes=1
and No=0. How do I establish the parameters for Yes and No to equal a numeric
result and then Total the result without creating a Macro? The text answer
needs to be visible: it is the result of a Yes/No choice.



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

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