Convert Daily Dataframe with Multi Index to quarterly
问题 I would like to convert my daily dataframe of stock data to a quarterly one. However, using resample did not work, because I have a multi index, so I would like my final quarterly dataframe to still contain the individual stocks (resample just summarizes all of them): import pandas as pd dict1 = [ {'ticker':'jpm','date': '2016-11-27','returns': 0.2}, {'ticker':'jpm','date': '2016-11-28','returns': 0.2}, {'ticker':'ge','date': '2016-11-27','returns': 0.2}, {'ticker':'ge','date': '2016-11-28',