Pandas data frame with time-series data – grouping without aggregating data
Pandas data frame with time-series data – grouping without aggregating data Question: I have the following pandas dataframe: import pandas as pd df4 = pd.DataFrame({‘timestamp’:[‘2022-10-01 01:00:00’, ‘2022-10-02 01:00:00’, ‘2022-10-03 01:00:00’, ‘2022-10-04 01:00:00’, ‘2022-10-05 01:00:00’, ‘2022-10-01 02:00:00’, ‘2022-10-02 02:00:00’, ‘2022-10-03 02:00:00’, ‘2022-10-04 02:00:00’, ‘2022-10-05 02:00:00’], ‘A’: [1,2,3,4,5,6,7,8,9,10], ‘B’: [10,9,8,7,6,5,4,3,2,1]} ) df4[‘timestamp’] = df4[‘timestamp’].astype(‘datetime64’) df4 that gives …