Willkommen, Gast
Benutzername: Passwort: Angemeldet bleiben:

THEMA: how to use sumifop in EM?

how to use sumifop in EM? 1 Jahr 10 Monate her #90951

  • bebs
  • bebss Avatar
  • OFFLINE
  • Senior Lime
  • Beiträge: 48
  • Dank erhalten: 2
  • Karma: 0
Hello.

What is the syntax of first argument (op) in sumifop(op, val1, val2,..)?
docs.limesurvey.org/Expression+Manager#Implemented_Functions


My answer label set is composed of a few "valid" results (eg 0->4) and a few possible answers that should give me different "error codes", such as "I don't know" or "not applicable" or "I don't understand the question".

I would like to sum up the answers of different questions using the same set, excluding automatically the error codes.

I guess one possible way is to associate to error codes negative values, and filter them out of the sum using sumifop, as in:
{sumifop(">0",Q1.value,Q2.value,Q3.value)} ... but I cannot figure the syntax of the first "op" argument: with hyphen it does not filter, without hyphens it does not parse.

Any pointer welcome, thanks.
Bebs.
Der Administrator hat öffentliche Schreibrechte deaktiviert.

Re: how to use sumifop in EM? 1 Jahr 10 Monate her #90952

  • bebs
  • bebss Avatar
  • OFFLINE
  • Senior Lime
  • Beiträge: 48
  • Dank erhalten: 2
  • Karma: 0
Sorry, I didn't read the documentation properly, as the right syntax is
number sumifop(op, value, arg1, arg2, ... argN)

I should have used
sumifop(">", 0, Q1.value, Q2.value...)

which works perfectly. thank you VERY much for this great feature!
Letzte Änderung: 1 Jahr 10 Monate her von bebs.
Der Administrator hat öffentliche Schreibrechte deaktiviert.

how to use sumifop in EM? 1 Jahr 1 Monat her #100375

  • limesun
  • limesuns Avatar
you can use sum(group),i am not sure ls has this.
Der Administrator hat öffentliche Schreibrechte deaktiviert.
Moderatoren: ITEd
Ladezeit der Seite: 0.144 Sekunden
Donation Image