RとSQliteの連携

http://www.okada.jp.org/RWiki/?SQLite
http://cran.r-project.org/web/packages/RSQLite/RSQLite.pdf


RSQLiteのインストール
$ sudo R
> install.packages("DBI")
> install.packages("RSQLite")
 
利用方法
$ R
> library(RSQLite)
> drv <- dbDriver("SQLite")
> con <- dbConnect(drv, dbname="test_db")
> test.table <- dbGetQuery(con, "select * from test_table;")
> dbDisconnect(con)

 

No comments:

Post a Comment

Nikkei225

28000-28550 up in the early session, down lately.