Skip to content

Tag: pandas

Pandas slow to merge and convert to datetime

I have two columns of data in a DataFrame containing a date and a time. Both start as strings. I want them to end up merged as a single column in datetime format. The head of the DataFrame is: They are in a DF called df_flattened and has about 20k rows and the code I am currently using is: However,

Compute time difference in pandas based on conditions [closed]

Closed. This question needs details or clarity. It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post. Closed 1 year ago. Improve this question I have a following problem. My data has this structure: I would like to calculate difference …