MyNixOS website logo
Description

Parameter Expanded Variational Bayes for High-Dimensional Linear Regression.

Implements a parameter expanded variational Bayes algorithm for linear regression models with high-dimensional variable selection. The methodology utilizes spike-and-slab priors to perform simultaneous estimation and selection. Details can be found in Olejua et al. (2024) <doi:10.21203/rs.3.rs-7208847/v1>.

spexvb: Parameter Expanded Variational Bayes for Sparse High-Dimensional Regression

CRAN status The spexvb package implements a Sparse Parameter-Expanded Variational Bayes algorithm for well-calibrated linear and logistic regression in high-dimensional settings. By utilizing parameter expansion and spike-and-slab priors, the methodology improves robustness to prior specifications and enhances predictive calibration compared to standard Variational Bayes.

Installation

You can install the released version of spexvb from CRAN with:

install.packages("spexvb")

Or the development version from GitHub:

# install.packages("devtools")
devtools::install_github("peterolejua/spexvb")

Quick Start Example

This example demonstrates how to perform cross-validation and fit the optimal model using simulated high-dimensional data.

library(spexvb)
library(doParallel)
cl <- makeCluster(min(2, parallel::detectCores())) 
registerDoParallel( cl)


# 1. Simulate high-dimensional data (n=100, p=500)
set.seed(17)
n <- 100
p <- 500
X <- matrix(rnorm(n * p), n, p)
true_beta <- c(rep(3, 5), rep(0, p - 5)) # 5 active predictors
Y <- X %*% true_beta + rnorm(n)

# 2. Perform 5-fold CV to find optimal tau_alpha and fit final model
fit <- cv.spexvb.fit(
  k = 5,
  X = X, 
  Y = Y,
  tau_alpha = c(0, 10^(3:6)), # Precision for expansion parameter alpha
  standardize = TRUE,
  intercept = TRUE
)

# 4. Visualize results
plot(true_beta, main = "True Coefficients", ylab = "Value")
plot(fit$beta, main = "Estimated Coefficients", ylab = "Value")
abline(h = 0, col = "red", lty = 2)

stopCluster(cl)

Authors

  • Peter Olejua - University of South Carolina

  • Enakshi Saha - University of South Carolina

  • Rahul Ghosal - University of South Carolina

  • Ray Bai - George Mason University

  • Alexander McLain - University of South Carolina

Citation

If you use this package in your research, please cite:

Olejua, P., Saha, E., Ghosal, R., Bai, R., & McLain, A. (2026). Parameter Expanded Variational Bayes for Well-Calibrated High-Dimensional Linear Regression with Spike-and-Slab Priors. Statistics and Computing, Under Revision. Preprint DOI: 10.21203/rs.3.rs-7208847/v1

Metadata

Version

0.1.0

License

Unknown

Platforms (78)

    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
  • 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
  • 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