Create Multi-Index empty DataFrame to join with main DataFrame
Suppose that I have a dataframe which can be created using code below df = pd.DataFrame(data = {‘date’:[‘2021-01-01’, ‘2021-01-02’, ‘2021-01-05′,’2021-01-02’, ‘2021-01-03’, ‘2021-01-05’], ‘product’:[‘A’, ‘A’, ‘A’, ‘B’, ‘B’, ‘B’], ‘price’:[10, 20, 30, 40, 50, 60] } ) df[‘date’] = pd.to_datetime(df[‘date’]) I want to create an empty dataframe let’s say main_df which will contain all dates between… Read More Create Multi-Index empty DataFrame to join with main DataFrame