Advertisement

R and Databases

Part of the Use R! book series (USE R)

While many tasks that used to be performed using relational databases can be easily implemented in R, there are some situations where using the power of a relational database nicely complements the capabilities of R. One obvious example are situations where the data to be used is stored in a relational database. Relational databases can also be used to make working with very large datasets easier.

The topic of administration of a database is beyond the scope of this book, and the assumption will always be made that you have access to a running database, and that enough permissions have been granted to perform the necessary database operations.

There are two principal ways to connect with databases in R. The first uses the ODBC (Open DataBase Connectivity) facility available on many computers. The second uses the DBI package of R along with a specialized package for the particular database needed to be accessed. If there is a specialized package available for your database, you may find that the corresponding DBI-based package may give better performance than the ODBC approach. On the other hand, if you are using a database for which a specialized package is not available, using ODBC may be your only option.

Keywords

Relational Database Aggregation Function Data Frame Database Table Head Line 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Copyright information

© Springer Science+Business Media, LLC 2008

Personalised recommendations