RE: [R] any book and tutorial about how to manipulate data with R /S+

From: Liaw, Andy <>
Date: Mon 14 Mar 2005 - 06:11:10 EST

> From: Wensui Liu
> I am sorry that I did not state my question clearly.
> What I mean by data manipulation includes sort, merge, aggregate,
> transpose,

R has functions for doing those: sort(), merge(), aggregate(), and t(), respectively.

> data export and import, format, date & time handle, and so
> on,

As others have pointed out, R comes with a manual on data import/export. There are articles in the R News that discuss date/time. Not sure what you mean by `format'.  

> which might be not important to statistician.

I beg to differ: Not too many statisticians (that I know of anyway) have the luxury of having data formatted and served on a silver platter for analysis.

> I have use SAS and SPSS for a while and really want to use R as an
> alternative computing system. Unless R/S+ can provide strong
> functionality in data manipulation as SAS does, it is hard to compete
> with SAS in business rather than in academic.

Let's see: I've been working at a pharmaceutical company for over five years now, and I can count the number of times I've used SAS during that period on one hand (and can't recall when was the last time). I do data manipulation all the time (mostly with R). Just last week I wrote a three-line function in R to read and parse a data file that's not in rectangular table format (so read.table and friends can't be used), while a colleague of mine tried to figure out how to do the same with Perl.

All the tasks you specified can be done in any number of packages/languages, some easier than others. I'd say R is one of the easiest, but that does require that you gain some familiarity with it. If you have specific questions, try search in the R-help archive, or if you can't find answer there, post the question here.


> On Sat, 12 Mar 2005 15:34:06 +0100, Thomas Schönhoff
> <> wrote:
> > Hallo,
> >
> > Am Samstag, 12. März 2005 15:08 schrieb Wensui Liu:
> > > In real world, data manipulation might take even longer time and
> > > more effort than statistical analysis and modeling.
> > >
> > > Does anyone know a good book and tutorial about data manupulation?
> > > Thank you so much.
> >
> > Well, it would be much easier to meet your demands if you could give
> > us an idea what you exactly looking for.
> > Anyway, there are some recommendations in R-Manual regarding
> > introduxtory materials on doing statistics in R. If I remember
> > correctly there are also some advices on in the generell
> > FAQ.
> > If you're looking for some introductory stuff doing data
> manipulation
> > in R the book of Peter Dalgaard, Introductory Statistics with R
> > should be taken into consideration.
> > Not long time ago there was a similar question to this list, giving
> > the whole range of available books on statistics in S/R .
> Have a look
> > at, you'll will be
> > overwhelmed.
> > Last but not least, if you look at r-cran website you'll find in
> > contributed section some case-oriented tutorials, i.e. data
> mining or
> > similar stuff!
> >
> > regards
> >
> > Thomas
> >
> > ______________________________________________
> > mailing list
> >
> > PLEASE do read the posting guide!
> >
> --
> WenSui Liu, MS MA
> Senior Decision Support Analyst
> Division of Health Policy and Clinical Effectiveness
> ______________________________________________
> mailing list
> PLEASE do read the posting guide!
> mailing list PLEASE do read the posting guide! Received on Mon Mar 14 12:43:31 2005

This archive was generated by hypermail 2.1.8 : Fri 03 Mar 2006 - 03:30:47 EST