Skip to main content
Question

Take total of a field and use it for percentage

  • September 13, 2017
  • 0 replies
  • 178 views

Hi,

I have a table which consists of questions whose answers are only Yes/No/NA. I would like to see total number of Yes,No and NA for all questions. I can sum them for only one row, but I want to do that for all table. After that, I want to take percentage of them without NA i.e.

 (total yes) / (total yes+ total no) and
 (total no) / (total yes+ total no) 

Then, I would like to have their graph as total yes-total no-total NA and percentage yes and no. 

How can I do this?

Thanks
This topic has been closed for replies.

  • Registered
  • September 14, 2017
Ideally all of these questions and answers would be child records (which provides much better reporting capabilities), but seeing as you just have the fields...

You will want to make 3 formula fields; # of Yes, # of No, # of N/A.

If the formula you use will be something to the affect of:
Sum(
If([Question 1]="Yes", 1, 0),
If([Question 2]="Yes", 1, 0),
If([Question 3]="Yes", 1, 0)
)

Repeat for all questions, then you can copy it and change the "Yes" to "No" and "N/A".

Now you will have numeric values that you can graph or count for your averages and totals.

  • Author
  • Registered
  • September 14, 2017
Thank you. I have already this formula, but this works for only one entry. What I want is sum all "Yes" answers from all entries in other words reaching total as can be found below.



Is there a way to reach these values? 

Try this

Make a new formula numeric percentage field called [Yes %]

var number Yes = Count(
[Q1] = "Yes",
[Q2] = "Yes",
[Q3] = "Yes",
[Q4] = "Yes",
[Q5] = "Yes");

Do the same for the NOs.

Then

$Yes / ($Yes + $No)

Then set that field to show averages and not totals