I am trying to generate a datetime index with pandas that has a custom daily frequency.
At the moment, I can generate the following datetime index:
import pandas as pd
import datetime as dt
pd.date_range(start=dt.datetime(2020,8,28),end=dt.datetime(2020,9,30),freq='B')
DatetimeIndex(['2020-08-28', '2020-08-31', '2020-09-01', '2020-09-02',
'2020-09-03', '2020-09-04', '2020-09-07', '2020-09-08',
'2020-09-09', '2020-09-10', '2020-09-11', '2020-09-14',
'2020-09-15', '2020-09-16', '2020-09-17', '2020-09-18',
'2020-09-21', '2020-09-22', '2020-09-23', '2020-09-24',
'2020-09-25', '2020-09-28', '2020-09-29', '2020-09-30'],
dtype='datetime64[ns]', freq='B')
However, this returns all the business days. I want to return all the Tue, Wed, Thur, Fri and Sat days instead. Perhaps this can be done with some kind of custom set up or some kind of offset? Specifically, is there a way to do it directly using the date_range functionality and the freq input? If not, how can this be achieved the most simply?
Thanks!