Hi Ellison, Thanks for pointing it out. Bad miss on my part.
Regards. On Wed, May 6, 2009 at 7:55 PM, S Ellison <s.elli...@lgc.co.uk> wrote: > The problem is in the code. > > When you say > >> mysummary<-tapply(myfactor,mydata,length) > >> mysummary > > you have used mydata as a factor and myfactor as the data. > > tapply has (correctly) used the ordered labels in the grouping factor > (mydata) to label its output. > > If you did what you probably intended: > tapply(mydata, myfactor,length) > > you'll get the order you expected. > > > > ******************************************************************* > This email and any attachments are confidential. Any u...{{dropped:15}} ______________________________________________ R-help@r-project.org 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.