Resample intraday pandas DataFrame without add new days

后端 未结 3 2112
别那么骄傲
别那么骄傲 2021-02-06 03:46

I want to downsample some intraday data without adding in new days

df.resample(\'30Min\')

Will add weekends etc which is undesirable. Is there

3条回答
  •  旧时难觅i
    2021-02-06 03:57

    The easiest workaround right now is probably something like:

    rs = df.resample('30min')
    rs[rs.index.dayofweek < 5]
    

提交回复
热议问题