calculate 0 or 1 depending on the date

Hello, I really don’t know how to develop this exercise in python. I do it relatively easily, but here it has been difficult for me.

And it is that I have to create an array that contains 0 for those dates below the established date and one above and 0 values ​​it above the cancellation date if it exists

result.xlsx (14.4 KB)

exercise.xlsx (14.4 KB)

I appreciate any help I really haven’t got anything useful

Hi @Jalvear

Since this is a KNIME forum, I have a possible solution for you in KNIME.
calculate_0_or_1.knwf (34.7 KB)

gr. Hans


Hello @HansS , thank you very much, it was what I was looking for, I appreciate your help, I did know that I had to make a loop but I did not find the way.

I only have one question, do you know any way to make this finish faster? Well, the sample that I pass you is relatively small compared to half a million data for what I have to do this, and the flow takes a couple of minutes

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