see sort_df() in the reshape package
 
Justin BEM
Elève Ingénieur Statisticien Economiste
BP 294 Yaoundé.
Tél (00237)9597295.

----- Message d'origine ----
De : Gunther Höning <gunther.hoening@ukmainz.de>
À : r-help@stat.math.ethz.ch
Envoyé le : Vendredi, 8 Juin 2007, 7h58mn 53s
Objet : [R] Sorting dataframe by different columns

Dear list,

I have a very short question,
Suggest a dataframe of four columns.

df <- data.frame(w,x,y,z)

I want this ordered the following way:
first by :x, decreasing = FALSE
and 
secondly by: z, decreasing =TRUE

How can this be done ?

Thanks

Gunther

______________________________________________
R-help@stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.







      _____________________________________________________________________________ 
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail 
	[[alternative HTML version deleted]]

