Number of elements that meet 2 or 3 conditions (repeat question)

Hello everyone, I am a beginner on kobocollect,
I want to calculate the Number of elements that meet 2 or 3 conditions
here is my attached file as an example.
I’m doing a little investigation and I want to be able to determine

  • the number of men over 18
  • the number of men aged over 25 and married
  • the number of single women
    SURVEY MATH.xlsx (10.2 KB)
    thank you for your support

@matsniper, you should be able to do it as outlined in the post discussed previously:

Hi @Kal_Lam , thank you for your answer but that’s not quite what I’m looking for. I want to determine the number of people who meet two or three conditions at the same time. example the number of men, married and aged 25.

Hello @matsniper
You can create a calculate variable inside the loop, with a combined if condition, and values 1, 0 (and empty). So, a sum(…) calculate variable after the loop will give you the combined result. If you want to show the result you can use a read_only number variable with a calculation.

hello @wroos, thank you for your answer.
as I said earlier, I’m a beginner, I’m not a good master of kobocollect so I would like to have an example illustrating what you suggest.

Can you please elaborate it more for me, I am not able to understand it fully,