Possible Duplicate:
How to sort a dataframe by column(s) in R
I am trying to sort a data.frame by several columns
df<-data.frame("Sp1"=c(7,4,2),"Sp2"=c(6,2,1))
row.names(df)<-c("A01","A02","A03")
    Sp1 Sp2
A01   7   6
A02   4   2
A03   2   1
#I am using    
df[with(df, order("Sp1"))]
however this does nothing. Any ideas why? Thanks
 
     
     
    