[R] Newbie question about SQL and data sources

David Whiting david.whiting at ncl.ac.uk
Sat Mar 25 06:42:53 CET 2006

Hi Rex,

Take a look at the Data Import/Export manual that ships with R to get a
feel for some of your options. I use a variety of techniques depending
on what I am doing. Quite often I use MySQL, accessing my tables via
RODBC. Other times text files are most appropriate. Then on other
occasions I am given datasets in DBF, stata, spss, or some other format
and use the foreign package to import them.

When I have tables of data that I know are not going to change I often
save them as Rdata files, document them and make a simple package of
them so that I can load them quickly and I have the information I need
about the dataset and variables to hand (very useful months later when
I've forgotten what half the variables represent). 


On Fri, 2006-03-24 at 23:13 -0500, Rex Eastbourne wrote:
> Hi,
> I just downloaded R, and am wondering about data sources.
> Where do people typically get their data for analysis? It seems to me
> most people would have their data somehow automatically gathered and
> stored in an SQL database (e.g. MySQL), but this seems not to be the
> case. Does everyone just use the plain-text tab-separated values
> format? If so, how are these tables typically created in the first
> place? I store a lot of data automatically in MySQL databases--is
> there another good way of aggregating data for statistical analysis
> that I might be unaware of?
> Thank you,
> Rex
> ______________________________________________
> R-help at 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

More information about the R-help mailing list