Category "multi-index"

pd.read_csv - dates in pandas multiindex column names

I import a csv file into a pandas dataframe. df=pd.read_csv('data.csv',index_col=[0],header=[0,1]) My data has a column multiindex with two levels. Level(0) co

Sort dataframe multiindex level and by column

#Updated: pandas version 0.23.0 solves this problem with Sorting by a combination of columns and index levels I have struggled with this and I suspect there is

Set MultiIndex of an existing DataFrame in pandas

I have a DataFrame that looks like Emp1 Empl2 date Company 0 0 0 2012-05-01 apple 1 0 1 2012-05-29