Math node if function

Hi KNIME Members,

I am not able to use the if function within the math formula node.

We have two columns: MaxPredictionValue and Holiday. The max prediction value columsn has multiple rows with a electricity usage value and the holiday column has the value 0 for not a holiday or the value 1 for when it is a holiday. I want to create a new column where we multiply the electricity usage value with 0.884 when the column holiday has a 1 in it.

Somehow I can’t get it working. Can someone show me what I am doing wrong?

Thank you in advance.

Try if($holiday$==1,$Prediction…$*0.884, $Prediction…$)
How about filter the rows out, create the calculated column and join it back?


Hey, your Syntax is wrong, there is no “=>” in the mathformula. Evaluation should be in the parenthesis as well. See the description of the if function for more infos


This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.