looping two columns when their time is close to each other by 30 sec

Viewed 31

I have two columns in a dataframe named [Timeline and Start] and their type is a timestamp.

I want to write a function that can set a threshold value = 30 seconds, and if the time in the start column is close to any value in the time of the Timeline column by the threshold value, this value from the start column will be moved under the Timeline column.

For example, insert 00:58:26 under 00:11:27 in the same start column if they have the difference in time of the threshold value.

enter image description here

0 Answers
Related