I worked now for quite some time using python and pandas for analysing a set of hourly data and find it quite nice (Coming from Matlab.)
Now I am kind of stuck. I cr
Pandas DataFrame has a built-in function pandas.DataFrame.between_time
df = pd.DataFrame(np.random.randn(1000, 2),
index=pd.date_range(start='2017-01-01', freq='10min', periods=1000))
Create 2 data frames for each period of time:
df1 = df.between_time(start_time='10:00', end_time='13:00')
df2 = df.between_time(start_time='20:00', end_time='23:00')
Data frame you want is merged and sorted df1 and df2:
pd.concat([df1, df2], axis=0).sort_index()