enclosed there are two pictures with an excel formula. I have a fixed value at the beginning and I want to use this value in the next row for a minus and plus calculation with fixed values of the current row.
How can I use a value from the row before?
Thank you.
Since you are saying that you have a fixed value “at the beginning” which means you have a value for the first row and missing for the rest of the rows in the initial dataset, using Lag Column node solely won’t solve your issue.
I think you need a recursive loop in which you filter the top 2 rows, calculate the base for the second row, pass the first row to the final output and concatenate the second row to the rest of table and pass it to the loop start.
I just added a workflow to my KNIME Hub area which does exactly this. I did use the cumulative computation option of the Moving Aggregation node to solve it.