{"id":32209294,"url":"https://github.com/wwiecek/baggr","last_synced_at":"2026-02-26T18:06:08.832Z","repository":{"id":38375695,"uuid":"140874292","full_name":"wwiecek/baggr","owner":"wwiecek","description":"R package for Bayesian meta-analysis models, using Stan","archived":false,"fork":false,"pushed_at":"2026-02-17T16:02:21.000Z","size":10248,"stargazers_count":49,"open_issues_count":43,"forks_count":12,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-02-17T17:09:27.219Z","etag":null,"topics":["bayesian-statistics","meta-analysis","quantile-regression","stan","treatment-effects"],"latest_commit_sha":null,"homepage":"","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wwiecek.png","metadata":{"files":{"readme":"readme.md","changelog":"NEWS.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2018-07-13T17:19:11.000Z","updated_at":"2026-02-17T16:12:29.000Z","dependencies_parsed_at":"2023-02-05T19:16:18.581Z","dependency_job_id":"cc35f0f7-bf7e-4a28-9142-74d52ac53b4f","html_url":"https://github.com/wwiecek/baggr","commit_stats":{"total_commits":511,"total_committers":7,"mean_commits":73.0,"dds":"0.23287671232876717","last_synced_commit":"9df8192738da476f1f45798179e40d99892ad833"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/wwiecek/baggr","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wwiecek%2Fbaggr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wwiecek%2Fbaggr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wwiecek%2Fbaggr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wwiecek%2Fbaggr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wwiecek","download_url":"https://codeload.github.com/wwiecek/baggr/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wwiecek%2Fbaggr/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29867158,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-26T16:38:37.846Z","status":"ssl_error","status_checked_at":"2026-02-26T16:37:58.932Z","response_time":89,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bayesian-statistics","meta-analysis","quantile-regression","stan","treatment-effects"],"created_at":"2025-10-22T06:02:21.294Z","updated_at":"2026-02-26T18:06:08.825Z","avatar_url":"https://github.com/wwiecek.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"# baggr: Bayesian aggregation package for R, v0.8 (2026)\n\n\n\n\u003c!-- badges: start --\u003e\n\n[![CRAN\\_Status\\_Badge](http://www.r-pkg.org/badges/version-last-release/baggr?color=green)](http://cran.r-project.org/package=baggr)\n[![](https://cranlogs.r-pkg.org/badges/baggr)](https://cran.rstudio.com/web/packages/baggr/index.html)\n[![Codecov\\_test\\_coverage](https://codecov.io/gh/wwiecek/baggr/branch/master/graph/badge.svg)](https://app.codecov.io/gh/wwiecek/baggr?branch=master)\n[![R-CMD-check](https://github.com/wwiecek/baggr/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/wwiecek/baggr/actions/workflows/R-CMD-check.yaml)\n\u003c!-- badges: end --\u003e\n\nThis is *baggr*, an [R package](https://www.r-project.org/) for Bayesian\nmeta-analysis using [Stan](https://mc-stan.org/). *Baggr* is intended to\nbe user-friendly and transparent so that it’s easier to understand the\nmodels you are building and criticise them.\n\n*Baggr* provides a suite of models that work with both summary data and\nfull data sets, to synthesise evidence collected from different groups,\ncontexts or time periods. The `baggr()` command automatically detects\nthe data type and, by default, fits a partial pooling model (which you\nmay know as [random effects\nmodels](https://stats.stackexchange.com/questions/4700/what-is-the-difference-between-fixed-effect-random-effect-and-mixed-effect-mode))\nwith weakly informative priors by calling [Stan](https://mc-stan.org/)\nto carry out Bayesian inference. Modelling of variances or quantiles,\nstandardisation and transformation of data is also possible.\n\nThe current version is a stable version of a tool that’s in active\ndevelopment so we are counting on your feedback.\n\n## Installation\n\nBefore starting, please follow [the installation instructions for\nRStan](https://github.com/stan-dev/rstan/wiki/RStan-Getting-Started),\nwhich is responsible for Bayesian inference in *baggr*. If you don’t\nhave Stan, it’s worth following the instructions step-by-step.\n\nThe package itself is available on CRAN:\n\n``` r\ninstall.packages(\"baggr\")\n```\n\nYou can also install the most up-to-date version of `baggr` directly\nfrom GitHub; this is what we recommend, but to do that you will need the\n`remotes` package:\n\n``` r\n#installation this way may take 5-15 minutes\nremotes::install_github(\"wwiecek/baggr\", \n                        ref = \"devel\", #if problems try changing to ref = \"master\"\n                        build_vignettes = TRUE, quiet = TRUE,\n                        build_opts = c(\"--no-resave-data\", \"--no-manual\"))\n```\n\nMost common issue in installing *baggr* is with updating other packages.\nTry updating your packages (and ensure R is at least version 4) before\ntrying the `remotes` command.\n\n## Basic use case\n\n`baggr` is designed to work well with both individual-level (“full”) and\naggregate/summary (“group”) data on treatment effect. In basic cases,\nonly the summary information on treatment effects (such as means and\ntheir standard errors) is needed. Data are always specified in a single\ninput data frame and the same `baggr()` function is used for different\nmodels.\n\nFor the “standard” cases of modelling means, the appropriate model is\ndetected from the shape of data.\n\n``` r\nlibrary(baggr)\ndf_pooled \u003c- data.frame(\"tau\" = c(28,8,-3,7,-1,1,18,12),\n                        \"se\"  = c(15,10,16,11,9,11,10,18))\nbg \u003c- baggr(df_pooled, pooling = \"partial\")\n```\n\nYou can specify the model type from several choices, the pooling type\n(`\"none\"`, `\"partial\"` or `\"full\"`), and certain aspects of the priors,\nas well as other options for data preparation, prediction and more. You\ncan access the underlying `stanfit` object through `bg$fit`.\n\nFlexible plotting methods are included, together with an automatic\ncomparison of multiple models (e.g. comparing no, partial and full\npooling) through `baggr_compare()` command. Various statistics can be\ncalculated: in particular, `pooling()` for pooling metrics and `loocv()`\nfor leave-one-group-out cross-validation, allowing us to then compare\nand select models via `loo_compare()`. Forest plots and plots of\ntreatment effects are available.\n\nTry `vignette('baggr')` for an overview of these functions and an\nexample of meta-analysis workflow with `baggr`. If working with binary\ndata, try `vignette(\"baggr_binary\")`. Compiled vignettes are available\n[on CRAN](https://cran.r-project.org/web/packages/baggr/index.html).\n\n## Current release\n\nIncluded in baggr v0.8 (2026):\n\n  - Meta-analysis of continuous and binary outcomes\n  - Both full and aggregate data sets can be used\n  - Summaries and plots specific to meta-analysis, typical diagnostic\n    plots\n  - Meta-regression / fixed effects modelling\n  - Compatibility with `rstan` and `bayesplot` features\n  - Automatic choice of priors or “plain-text” specification of priors\n  - Calculation of pooling/heterogeneity metrics\n  - Cross-validation (leave-one-group-out)\n  - Prior and posterior predictive distributions\n  - Selection models based on \\|z\\| thresholds (`selection = ...`)\n  - Funnel plots for fitted objects via `funnel_plot()`\n\nCheck [NEWS.md] for more information on recent changes to the package.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwwiecek%2Fbaggr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwwiecek%2Fbaggr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwwiecek%2Fbaggr/lists"}