SQLite with R

In this part of the chapter, we will query a SQLite database installed on a local, personal computer directly from RStudio. But before we can do it, follow the next section to prepare a SQLite database and read the data in.

Preparing and importing data into a local SQLite database

We mentioned earlier that SQLite is, by default, included in some distributions of popular operating systems, for example Mac OS X (since version 10.4) and in Windows 10. You can easily check whether your machine has SQLite installed by starting it through a Terminal/shell window:

$ sqlite3
SQLite version 3.12.1 2016-04-08 15:09:49
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database. ...

Get Big Data Analytics with R now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.