When the column "event" has a value different than 0, and rows above from column "input1" has value 5, I need to copy the value from row above of column "label".
What I have now:
input1 input2 input3 event label
0 0 0 0 0
5 5 0 0 2
5 5 0 0 2
0 0 0 24 0
0 0 0 0 0
5 0 5 0 3
5 0 5 0 3
5 0 5 0 3
0 0 0 25 0
0 0 0 0 0
What I need to happen:
input1 input2 input3 event label marker
0 0 0 0 0 0
5 5 0 0 2 0
5 5 0 0 2 0
0 0 0 24 0 2
0 0 0 0 0 0
5 0 5 0 3 0
5 0 5 0 3 0
5 0 5 0 3 0
0 0 0 25 0 3
0 0 0 0 0 0