{
  "_id": "6a0f720facfb0bcc41c5fa04",
  "Package": "dbreg",
  "Type": "Package",
  "Title": "Fast Regressions on Database Backends",
  "Version": "0.0.3.99",
  "Date": "2026-03-16",
  "Authors@R": "c(\nperson(\ngiven = \"Grant\",\nfamily = \"McDermott\",\nrole = c(\"aut\", \"cre\"),\nemail = \"contact@grantmcdermott.com\",\ncomment = c(ORCID = \"0000-0001-7883-8573\")\n),\nperson(\ngiven = \"James\",\nfamil = \"Brand\",\nemail = \"jamesbrandecon@gmail.com\",\nrole = c(\"aut\"),\ncomment = c(ORCID = \"0000-0002-1663-5583\")\n),\nperson(\ngiven = \"Apoorva\",\nfamil = \"Lal\",\nemail = \"lal.apoorva@gmail.com\",\nrole = c(\"ctb\"),\ncomment = c(ORCID = \"0000-0002-3697-614X\")\n),\nperson(\ngiven = \"Laurent\",\nfamil = \"Berge\",\nemail = \"laurent.berge@u-bordeaux.fr\",\nrole = c(\"ctb\")\n)\n)",
  "Description": "Leverages database backends to run regressions on very\nlarge datasets, which may not fit into R's memory. Various\nacceleration strategies---e.g., Wong et al. (2021)\n<doi:10.48550/arXiv.2102.11297> and Arkhangelsky & Imbens\n(2024) <https://doi.org/10.1093/restud/rdad089>---allow for\nhighly efficient computation, while robust standard errors are\ncomputed from sufficient statistics.",
  "Config/Needs/website": "etiennebacher/altdoc",
  "Encoding": "UTF-8",
  "License": "MIT + file LICENSE",
  "URL": "https://grantmcdermott.com/dbreg/",
  "BugReports": "https://github.com/grantmcdermott/dbreg/issues",
  "VignetteBuilder": "quarto",
  "Config/roxygen2/version": "8.0.0",
  "Config/pak/sysreqs": "xz-utils",
  "Repository": "https://grantmcdermott.r-universe.dev",
  "Date/Publication": "2026-05-21 19:39:46 UTC",
  "RemoteUrl": "https://github.com/grantmcdermott/dbreg",
  "RemoteRef": "HEAD",
  "RemoteSha": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
  "NeedsCompilation": "no",
  "Packaged": {
    "Date": "2026-05-21 20:55:27 UTC",
    "User": "root"
  },
  "Author": "Grant McDermott [aut, cre] (ORCID:\n<https://orcid.org/0000-0001-7883-8573>),\nJames Brand [aut] (ORCID: <https://orcid.org/0000-0002-1663-5583>),\nApoorva Lal [ctb] (ORCID: <https://orcid.org/0000-0002-3697-614X>),\nLaurent Berge [ctb]",
  "Maintainer": "Grant McDermott <contact@grantmcdermott.com>",
  "MD5sum": "e6b3bb54a13abade77bedf6e41eb5cb3",
  "_user": "grantmcdermott",
  "_type": "src",
  "_file": "dbreg_0.0.3.99.tar.gz",
  "_fileid": "30dc5c45cb20f1ad356f26daa0ba8cba48e18cf435acad3898272edbb6bb28de",
  "_filesize": 378331,
  "_sha256": "30dc5c45cb20f1ad356f26daa0ba8cba48e18cf435acad3898272edbb6bb28de",
  "_created": "2026-05-21T20:55:27.000Z",
  "_published": "2026-05-21T20:58:55.217Z",
  "_distro": "noble",
  "_jobs": [
    {
      "job": 77267329783,
      "time": 174,
      "config": "linux-devel-x86_64",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "7147068020"
    },
    {
      "job": 77267329787,
      "time": 162,
      "config": "linux-release-x86_64",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7147064483"
    },
    {
      "job": 77267329841,
      "time": 119,
      "config": "macos-oldrel-arm64",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "7147050751"
    },
    {
      "job": 77267329778,
      "time": 120,
      "config": "macos-release-arm64",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7147050757"
    },
    {
      "job": 77266776115,
      "time": 192,
      "config": "source",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7147011554"
    },
    {
      "job": 77267329799,
      "time": 125,
      "config": "wasm-release",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7147052734"
    },
    {
      "job": 77267329811,
      "time": 138,
      "config": "windows-devel",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "7147057191"
    },
    {
      "job": 77267329810,
      "time": 132,
      "config": "windows-oldrel",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "7147055290"
    },
    {
      "job": 77267329816,
      "time": 111,
      "config": "windows-release",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "7147048136"
    }
  ],
  "_buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951",
  "_status": "success",
  "_host": "GitHub-Actions",
  "_upstream": "https://github.com/grantmcdermott/dbreg",
  "_commit": {
    "id": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
    "author": "Grant McDermott <grant.mcdermott@gmail.com>",
    "committer": "GitHub <noreply@github.com>",
    "message": "Refactor: inputs environment + code modularization (#65)\n\n* refactor: convert inputs from list to environment\n\nUse list2env() in process_dbreg_inputs() so that downstream functions\n(choose_strategy, execute_*_strategy) can mutate shared state in place.\nThis fixes a latent bug where choose_strategy() mutations (is_balanced,\ncompression_ratio_est) were silently lost due to R's copy-on-modify\nlist semantics.\n\nAlso adds env2env() helper (from tinyplot) for explicit read/write\ncontracts between functions and environments.\n\n* refactor: replace inputs$ access with inputs[[\"\"]]\n\nAvoid partial matching and align with tinyplot's convention of using\n[[ for element access on environments and lists. Also extracts yvar\nas a local variable in execute_demean_strategy to avoid quoting\nconflicts inside glue() interpolation.\n\n* refactor: replace $ with [[ access, convert dbbinsreg inputs to env\n\n- Replace all inputs$ with inputs[[\"\"]] in both dbreg.R and dbbinsreg.R\n  to avoid partial matching (aligns with tinyplot convention)\n- Convert dbbinsreg inputs from list to environment for consistency\n- Document the inputs environment pattern in CLAUDE.md and\n  process_dbreg_inputs() roxygen\n\n* refactor: extract vcov/meat functions to R/vcov.R\n\nMove compute_vcov(), compute_meat_sql(), compute_meat_cluster_sql(),\nand compute_meat_cluster_compress() from dbreg.R to a dedicated\nvcov.R file. These are shared across all strategies and have a\nwell-defined interface, making them a natural extraction target.\n\nAlso converts dbbinsreg inputs to environment and documents the\ninputs environment pattern in CLAUDE.md.\n\n* refactor: extract strategies to R/strategies.R, move gen_xvar_pairs to utils\n\nMove execute_moments_strategy(), execute_demean_strategy(),\nexecute_mundlak_strategy(), execute_compress_strategy(), and\ncount_nested_fe_levels() to R/strategies.R. Move gen_xvar_pairs()\nto R/utils.R (shared by strategies and SQL helpers).\n\ndbreg.R is now ~1040 lines (down from ~2600): public API, input\nprocessin",
    "time": 1779392386
  },
  "_maintainer": {
    "name": "Grant McDermott",
    "email": "contact@grantmcdermott.com",
    "orcid": "0000-0001-7883-8573"
  },
  "_registered": true,
  "_dependencies": [
    {
      "package": "DBI",
      "role": "Imports"
    },
    {
      "package": "duckdb",
      "role": "Imports"
    },
    {
      "package": "Formula",
      "role": "Imports"
    },
    {
      "package": "generics",
      "role": "Imports"
    },
    {
      "package": "glue",
      "role": "Imports"
    },
    {
      "package": "MASS",
      "role": "Imports"
    },
    {
      "package": "Matrix",
      "role": "Imports"
    },
    {
      "package": "stats",
      "role": "Imports"
    },
    {
      "package": "tinyplot",
      "role": "Imports"
    },
    {
      "package": "binsreg",
      "role": "Suggests"
    },
    {
      "package": "here",
      "role": "Suggests"
    },
    {
      "package": "fixest",
      "version": ">= 0.13.0",
      "role": "Suggests"
    },
    {
      "package": "knitr",
      "role": "Suggests"
    },
    {
      "package": "quarto",
      "role": "Suggests"
    },
    {
      "package": "tinytest",
      "role": "Suggests"
    },
    {
      "package": "dbplyr",
      "role": "Enhances"
    }
  ],
  "_owner": "grantmcdermott",
  "_selfowned": true,
  "_usedby": 0,
  "_updates": [
    {
      "week": "2025-34",
      "n": 6
    },
    {
      "week": "2025-35",
      "n": 11
    },
    {
      "week": "2025-42",
      "n": 1
    },
    {
      "week": "2025-44",
      "n": 1
    },
    {
      "week": "2025-45",
      "n": 1
    },
    {
      "week": "2025-50",
      "n": 1
    },
    {
      "week": "2025-51",
      "n": 4
    },
    {
      "week": "2025-52",
      "n": 3
    },
    {
      "week": "2026-01",
      "n": 3
    },
    {
      "week": "2026-02",
      "n": 6
    },
    {
      "week": "2026-03",
      "n": 2
    },
    {
      "week": "2026-04",
      "n": 3
    },
    {
      "week": "2026-05",
      "n": 2
    },
    {
      "week": "2026-11",
      "n": 1
    },
    {
      "week": "2026-12",
      "n": 1
    },
    {
      "week": "2026-21",
      "n": 4
    }
  ],
  "_tags": [
    {
      "name": "v0.0.3",
      "date": "2026-01-24"
    }
  ],
  "_stars": 78,
  "_contributors": [
    {
      "user": "grantmcdermott",
      "count": 109,
      "uuid": 10285037
    },
    {
      "user": "jamesbrandecon",
      "count": 11,
      "uuid": 62019331
    },
    {
      "user": "etiennebacher",
      "count": 2,
      "uuid": 52219252
    }
  ],
  "_userbio": {
    "uuid": 10285037,
    "type": "user",
    "name": "Grant McDermott",
    "description": "Principal Economist at Amazon. Mix of economics, data science, and open source."
  },
  "_downloads": {
    "count": 0,
    "source": "https://cranlogs.r-pkg.org/downloads/total/last-month/dbreg"
  },
  "_devurl": "https://github.com/grantmcdermott/dbreg",
  "_pkgdown": "https://grantmcdermott.com/dbreg/",
  "_searchresults": 20,
  "_rbuild": "4.6.0",
  "_assets": [
    "extra/citation.cff",
    "extra/citation.html",
    "extra/citation.json",
    "extra/citation.txt",
    "extra/contents.json",
    "extra/dbreg.html",
    "extra/NEWS.html",
    "extra/NEWS.txt",
    "extra/readme.html",
    "extra/readme.md",
    "manual.pdf"
  ],
  "_cranurl": false,
  "_exports": [
    "dbbinsreg",
    "dbreg",
    "glance",
    "gof",
    "sql_model_matrix",
    "tidy"
  ],
  "_help": [
    {
      "page": "coef.dbreg",
      "title": "Extract coefficients from dbreg objects",
      "topics": [
        "coef.dbreg"
      ]
    },
    {
      "page": "confint.dbreg",
      "title": "Confidence intervals for dbreg objects",
      "topics": [
        "confint.dbreg"
      ]
    },
    {
      "page": "dbbinsreg",
      "title": "Run a binscatter regression on a database backend and plot the result",
      "topics": [
        "dbbinsreg"
      ]
    },
    {
      "page": "dbreg",
      "title": "Run a regression on a database backend",
      "topics": [
        "dbreg"
      ]
    },
    {
      "page": "gof",
      "title": "Calculate goodness-of-fit metrics for dbreg objects",
      "topics": [
        "gof"
      ]
    },
    {
      "page": "plot.dbbinsreg",
      "title": "Plot method for dbbinsreg objects",
      "topics": [
        "plot.dbbinsreg",
        "tinyplot.dbbinsreg"
      ]
    },
    {
      "page": "predict.dbreg",
      "title": "Predict method for dbreg objects",
      "topics": [
        "predict.dbreg"
      ]
    },
    {
      "page": "print.dbbinsreg",
      "title": "Print method for dbbinsreg objects (binsreg-compatible format)",
      "topics": [
        "print.dbbinsreg"
      ]
    },
    {
      "page": "print.dbreg",
      "title": "Print method for dbreg objects",
      "topics": [
        "print.dbreg"
      ]
    },
    {
      "page": "sql_model_matrix",
      "title": "Construct SQL expressions for a design matrix",
      "topics": [
        "sql_model_matrix"
      ]
    },
    {
      "page": "tidiers",
      "title": "Tidiers for `dbreg` objects",
      "topics": [
        "glance.dbreg",
        "tidiers",
        "tidy.dbreg"
      ]
    },
    {
      "page": "vcov.dbreg",
      "title": "Variance-covariance matrix for dbreg objects",
      "topics": [
        "vcov.dbreg"
      ]
    }
  ],
  "_readme": "https://github.com/grantmcdermott/dbreg/raw/HEAD/README.md",
  "_rundeps": [
    "DBI",
    "duckdb",
    "Formula",
    "generics",
    "glue",
    "lattice",
    "MASS",
    "Matrix",
    "tinyplot"
  ],
  "_score": 5.397244581010386,
  "_indexed": true,
  "_nocasepkg": "dbreg",
  "_universes": [
    "grantmcdermott"
  ],
  "_binaries": [
    {
      "r": "4.7.0",
      "os": "linux",
      "version": "0.0.3.99",
      "date": "2026-05-21T20:57:51.000Z",
      "distro": "noble",
      "commit": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
      "fileid": "6d135439674f8e851406e5230fa363800d942c5b0286dc0742d504c7fcc2163e",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951"
    },
    {
      "r": "4.6.0",
      "os": "linux",
      "version": "0.0.3.99",
      "date": "2026-05-21T20:57:42.000Z",
      "distro": "noble",
      "commit": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
      "fileid": "c408711b14b73c63abe00e5a7370a84417442a227bb5518458e3530c69379825",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951"
    },
    {
      "r": "4.5.3",
      "os": "mac",
      "version": "0.0.3.99",
      "date": "2026-05-21T20:57:08.000Z",
      "commit": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
      "fileid": "d5a3540ef5a05e369bdbedabeec870f83d15c0adbfdb4822ddc50b3ba73a0eb0",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951"
    },
    {
      "r": "4.6.0",
      "os": "mac",
      "version": "0.0.3.99",
      "date": "2026-05-21T20:57:11.000Z",
      "commit": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
      "fileid": "1600f0ab328d1893c6c0ca3dd9036bbc547e7e8226888ff1ee726a707290ae8f",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951"
    },
    {
      "r": "4.6.0",
      "os": "wasm",
      "version": "0.0.3.99",
      "date": "2026-05-21T20:57:51.000Z",
      "commit": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
      "fileid": "2d80ef59d654e016a8a4e95b39b1cd218b44e2bd23fe07a97e44b678438743dd",
      "status": "success",
      "buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951"
    },
    {
      "r": "4.7.0",
      "os": "win",
      "version": "0.0.3.99",
      "date": "2026-05-21T20:57:12.000Z",
      "commit": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
      "fileid": "f6dd3738d598e93aea09706a4f1c6c2ed53a64b578f9e8a52a7458108fe24818",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951"
    },
    {
      "r": "4.5.3",
      "os": "win",
      "version": "0.0.3.99",
      "date": "2026-05-21T20:57:07.000Z",
      "commit": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
      "fileid": "d36384fbbf411099def8f12d95749d68a875542360019d1d5a5abc90ca676556",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951"
    },
    {
      "r": "4.6.0",
      "os": "win",
      "version": "0.0.3.99",
      "date": "2026-05-21T20:56:43.000Z",
      "commit": "26ab3226aebb324a9f9d6943fafb6366d21e2042",
      "fileid": "ffacffa47bbc0cf7a64eb00593dd52393673df54859d849946852ca50d94e24d",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/grantmcdermott/actions/runs/26252430951"
    }
  ]
}