Learn R Programming

⚠️There's a newer version (0.10.0) of this package.Take me there.

duckdb R package

Installation from CRAN

install.packages("duckdb")

Building

The default build compiles a release version from an amalgamation.

cd tools/rpkg
R CMD INSTALL .

Optional extensions can be enabled by passing them (comma-separated, if there is more than one) to the environment variable DUCKDB_R_EXTENSIONS:

DUCKDB_R_EXTENSIONS=tpch R CMD INSTALL .

Development

For development, setting the DUCKDB_R_DEBUG environment variable enables incremental debugging builds for the R package.

cd tools/rpkg
DUCKDB_R_DEBUG=1 R CMD INSTALL .

This also works for devtools:

Sys.setenv(DUCKDB_R_DEBUG = "1")
pkgload::load_all()

Add the following to your .Renviron to make this the default:

DUCKDB_R_DEBUG=1

If you do this, remember to use --vanilla for building release builds.

Copy Link

Version

Install

install.packages('duckdb')

Monthly Downloads

20,522

Version

0.6.2

License

MIT + file LICENSE

Issues

Pull Requests

Stars

Forks

Maintainer

Hannes Muehleisen

Last Published

January 16th, 2023

Functions in duckdb (0.6.2)

backend-duckdb

DuckDB SQL backend for dbplyr
duckdb_get_substrait

Get the Substrait plan for a SQL query Transforms a SQL query into a raw vector containing the serialized Substrait query blob
duckdb_prepare_substrait

Query DuckDB using Substrait Method for interpreting a Substrait BLOB plan as a DuckDB Query Plan It interprets and executes the query.
duckdb

Connect to a DuckDB database instance
duckdb_connection-class

DuckDB connection class
duckdb-package

DuckDB client package for R
duckdb_explain-class

DuckDB EXPLAIN query tree
duckdb_get_substrait_json

Get the Substrait plan for a SQL query in the JSON format Transforms a SQL query into a vector containing the serialized Substrait query JSON
duckdb_register_arrow

Register an Arrow data source as a virtual table
duckdb_register

Register a data frame as a virtual table
duckdb_read_csv

Reads a CSV file into DuckDB
duckdb_prepare_substrait_json

Query DuckDB using Substrait Method for interpreting a Substrait JSON plan as a DuckDB Query Plan It interprets and executes the query.
duckdb_driver-class

DuckDB driver class
read_csv_duckdb

Deprecated functions
duckdb_result-class

DuckDB Result Set