MyNixOS website logo
Description

Privacy-Preserving Meta-Analysis via Low-Rank Basis Hunting.

Tools for privacy-preserving meta-analysis of function-valued quantities across heterogeneous studies. Implements the 'MetaHunt' pipeline, including the denoised functional Successive Projection Algorithm (d-fSPA) for basis hunting, constrained weight estimation, Dirichlet regression of weights on study-level covariates, target prediction, and split/cross conformal prediction intervals. Operates on aggregate-level function evaluations, so individual-level data from source studies are not required. Methodology described in Shi, Imai, and Zhang (2026) <doi:10.48550/arXiv.2604.23847>.

MetaHunt MetaHunt website

R-CMD-check pkgdown Lifecycle: experimental License: MIT

MetaHunt is an R package for privacy-preserving meta-analysis of function-valued quantities (e.g. regression functions, conditional average treatment effect functions) across heterogeneous studies (Shi, Imai, & Zhang 2024, arXiv:2604.23847).

Documentation: https://wshi18.github.io/MetaHunt/

The package implements the methodology of

Shi, W., Imai, K., and Zhang, Y. Privacy-preserving Meta-analysis through Low-Rank Basis Hunting.

Given aggregate-level estimates of a function of interest from several source studies, together with study-level covariates, MetaHunt recovers a small set of latent basis functions that span all studies under a low-rank assumption, models how the mixing weights depend on study-level covariates via Dirichlet regression, and predicts the corresponding function for a new target population with valid conformal prediction intervals. Individual-level data from source studies are not required, which makes the procedure suitable for federated and multi-site settings.

The package also exports minmax_regret(), a covariate-free baseline based on the worst-case-regret aggregator of Zhang, Huang, and Imai (2024, arXiv:2412.11136). It is useful when the number of source studies is small or the study-level covariates are uninformative.

Installation

# install.packages("remotes")
remotes::install_github("WShi18/MetaHunt")

Quick example

library(MetaHunt)
set.seed(1)

# Simulate m studies, each represented by its function on a shared grid.
G <- 30; m <- 60
x <- seq(0, 1, length.out = G)
basis <- rbind(sin(pi * x), cos(pi * x), x)
W <- data.frame(w1 = rnorm(m), w2 = rnorm(m))
eta <- as.matrix(W) %*% cbind(c(1, -0.5), c(-0.4, 1), c(0, 0))
pi_true <- exp(eta) / rowSums(exp(eta))
F_hat <- pi_true %*% basis + matrix(rnorm(m * G, sd = 0.05), m, G)

# Fit and predict for a new study with W_new = (0, 0).
fit   <- metahunt(F_hat, W, K = 3, dfspa_args = list(denoise = FALSE))
W_new <- data.frame(w1 = 0, w2 = 0)
pred  <- predict(fit, newdata = W_new, wrapper = mean)

# 95% conformal interval for the same target.
ci <- split_conformal(F_hat, W, W_new, K = 3,
                      wrapper = mean, alpha = 0.05, seed = 1,
                      dfspa_args = list(denoise = FALSE))
ci$prediction
c(ci$lower, ci$upper)

See vignette("metahunt-intro") for a full walkthrough including data preparation from fitted model objects, rank selection, conformal intervals (split / cross / pre-fit), and the minimax-regret baseline.

Methods provided

  1. metahunt() + predict(), plot(), summary() — end-to-end fitter.
  2. split_conformal(), cross_conformal(), conformal_from_fit() — prediction intervals.
  3. coverage(), summary.metahunt_conformal() — conformal diagnostics.
  4. minmax_regret() — covariate-free worst-case-regret baseline (Zhang, Huang, & Imai 2024).
  5. reconstruction_error_curve(), cv_error_curve() — rank-selection diagnostics.
  6. select_denoising_params() — cross-validated tuning of (N, Delta).
  7. f_hat_from_models(), build_grid() — onramp from fitted-model lists to the package's matrix inputs.

The individual pipeline building blocks (dfspa(), project_to_simplex(), fit_weight_model(), predict_target(), apply_wrapper()) are also exported and can be composed independently.

Citation

If you use MetaHunt in academic work, please cite:

Shi, W., Imai, K., and Zhang, Y. (2024). Privacy-preserving meta-analysis through low-rank basis hunting. arXiv:2604.23847. https://arxiv.org/abs/2604.23847

Status

v0.1.0 is the first GitHub release. The API is stabilising; user feedback is welcome via issues.

License

MIT © Wenqi Shi, Kosuke Imai, Yi Zhang.

Metadata

Version

0.1.0

License

Unknown

Platforms (80)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    uefi
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-freebsd
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64-uefi
  • aarch64-windows
  • aarch64_be-none
  • arc-linux
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-linux
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • sh4-linux
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-uefi
  • x86_64-windows