I have the following data:
Set Coolthing Route Organ Up Down
set4 Pam3CSK4 ID LL 81 60
set4 Poly_IC ID LL 542 92
set4 Poly_IC ID MM 73 73
set4 cdiGMP ID MM 143 78
set4 Poly_IC ID BB 32 82
set4 cdiGMP ID BB 90 129
With the following code:
import pandas as pd
df = pd.io.parsers.read_table("http://dpaste.com/2PHS7R0.txt",sep=" ")
df = df.pivot(index="Coolthing",columns="Organ").fillna(0)
df.drop('Set',axis=1,inplace=True)
df.drop('Route',axis=1,inplace=True)
df.index.name = None
df.columns.names = (None,None)
I get the following:
In [75]: df
Out[75]:
Up Down
BB LL MM BB LL MM
Pam3CSK4 0 81 0 0 60 0
Poly_IC 32 542 73 82 92 73
cdiGMP 90 0 143 129 0 78
What I want to do is to sort the row with case insensitive way yielding this:
Up Down
BB LL MM BB LL MM
cdiGMP 90 0 143 129 0 78
Pam3CSK4 0 81 0 0 60 0
Poly_IC 32 542 73 82 92 73
How can I achieve that?