In a “column list loop”, I would like to count the values -9999. My column is an integer. But when I put if($[currentColumnName] = -9999, 1, 0)
indicate by K-IA !!
it tells me
Operator ‘==’ is not applicable for STRING and INTEGER
When I put if($$[“currentColumnName”] => ‘-9999’,1,0)
nothing comes out (no 1 in the row)
I even tried
if(join(“”,“$[\‘’,string($$currentColumnName),”\“]”) = -9999,1,0)
How can I count these -9999 values in my column?
thx for your help, I hope this is more useful than the AI
the variable “currentColumnName” is just the name of the current column. Therefore the expression does not test the “CurrentColumn” but the name of the current column if its called “-9999”
Maybe there’s a more efficient approach than mine, but in the case of a column wise looping I rename the current column to a generic name, apply the math operations and rename it back: