dbcooper: Turn any database into an R or Python package
summary
dbcooper turns a DBI connection into an opinionated API that generates prefixed functions (e.g. dbc_init) and one accessor per table so queries become autocomplete-friendly accessors rather than juggling a connection object. Implements R (dbplyr) and Python (siuba) ports and shows concrete builds: a lahman demo, a New York Times COVID BigQuery example, and a stackbigquery wrapper for Stack Overflow. Google BigQuery lists 239 public DBs, so the package’s approach scales, and the demos show exploration feels fluid and works.
AI-written summary · about
chapters (8)
- 0:00Start
- 4:00Example: Get a remote table
- 4:17Example: Run a SQL query
- 4:34Example: Execute a command
- 8:14Access tables with autocomplete
- 13:00Write database-specific connection code
- 13:12Add code to zzz.R to run dbc_init()
- 13:56Add any database-specific verbs
related talks
19mDatabases using R The latest
33mturbodbc: Turbocharged Database Access for Data Scientists
59mIntroduction to Python Database Programming
20mSiuba and duckdb: Analyzing Everything Everywhere All at Once
17mEasing the pain of connecting to databases
01h 17mIbis: A fast, flexible, and portable tool for data analytics
22mDuckDBT: Not a database or a dbt adapter but a secret third thing
18mduckplyr: Tight Integration of duckdb with R and the tidyverse
