Summarize - Count of checkboxes

I have a table with a number of checkbox columns. Each row represents a person and each column is a task completed. I want to summarize each column at the bottom to show the people that completed each task.

image

However, the count includes all rows, regardless of whether the box is checked or not. Is it possible to count only if checkbox = true, so that my totals at the bottom of the table only include the number of people that have completed each task?

Hi @Jamie_Fall
and welcome to Coda Community! :handshake:

Unfortunately you can’t provide conditional summaries.
As a workaround you can:

  1. Add an additional column for each boolean to set numeric values with a formula:
    If([CheckColumn], 1,0)
    and then jus summarise by Sum
  2. Create a canvas variable holding the sum of true values
    [Your Table].CountIf([CheckColumn])

I hope this helps.
Cheers

Hi @Jamie_Fall,

Checkboxes actually have three values: TRUE, FALSE, and null. If you set the blank ones to null (by deleting the ‘blank’ value), then Count will handle it the way you intended. GIF below.

You can also set the value for new rows to be null by changing the new row value to be a formula with no value. Just enter it as a blank cell in the column options.

Hope that’s helpful!

Shared with CloudApp

1 Like

how can we delete a blank value?

If you set the blank ones to null (by deleting the ‘blank’ value)

thanks, Christiaan

I think he means ‘false’ which is the checkbox being blank. You can see in his gif the difference between the light grey (null) and the grey (false). In both cases they are blank.

hit the delete key when you are in the cell with the checkbox to get NULL

1 Like