biglasso extends lasso and elastic-net linear and logistic regression models for ultrahigh-dimensional, multi-gigabyte data sets that cannot be loaded into memory. It utilizes memory-mapped files to store the massive data on the disk and only read those into memory whenever necessary during model fitting. In addition, some advanced feature screening rules are proposed and implemented to accelerate the model fitting. To the best of our knowledge, biglasso is the only R package that enables users to fit lasso models with data sets that are larger than available RAM, enabling big data analysis on an ordinary laptop.
For more documentation, visit the biglasso website.
Installation
To install the latest stable release version from CRAN:
install.packages("biglasso")To install the latest development version from GitHub:
remotes::install_github("pbreheny/biglasso")Features
- It utilizes memory-mapped files to store the massive data on the disk, only loading data into memory when necessary during model fitting. Consequently, it’s able to seamlessly handle out-of-core computation.
- It is built upon pathwise coordinate descent algorithm with warm start, active set cycling, and feature screening strategies, which has been proven to be one of fastest lasso solvers.
- We develop new, adaptive feature screening rules that outperform state-of-the-art screening rules such as the sequential strong rule (SSR) and the sequential EDPP rule (SEDPP) with additional 1.5x to 4x speedup.
- The implementation is designed to be as memory-efficient as possible by eliminating extra copies of the data created by other R packages, making
biglassoat least 2x more memory-efficient thanglmnet. - The underlying computation is implemented in C++, and parallel computing with OpenMP is also supported.
Benchmarks
biglasso is substantially more memory-efficient than glmnet, ncvreg, and picasso on both simulated and real data sets, is competitive with or faster than them on computing time, and can fit lasso models on data too large to fit in RAM at all. See here for benchmarks.
Reference
- Zeng Y and Breheny P (2021). The biglasso Package: A Memory- and Computation-Efficient Solver for Lasso Model Fitting with Big Data in R. R Journal, 12: 6–19. https://doi.org/10.32614/RJ-2021-001
- Zeng Y, Yang T, and Breheny P (2021). Hybrid safe-strong rules for efficient optimization in lasso-type problems. Computational Statistics and Data Analysis, 153: 107063. https://doi.org/10.1016/j.csda.2020.107063
- Wang C and Breheny P (2022). Adaptive hybrid screening for efficient lasso optimization. Journal of Statistical Computation and Simulation, 92: 2233–2256. https://doi.org/10.1080/00949655.2021.2025376
- Tibshirani, R., Bien, J., Friedman, J., Hastie, T., Simon, N., Taylor, J., and Tibshirani, R. J. (2012). Strong rules for discarding predictors in lasso-type problems. Journal of the Royal Statistical Society: Series B (Statistical Methodology), 74: 245–266.
- Wang, J., Zhou, J., Wonka, P., and Ye, J. (2013). Lasso screening rules via dual polytope projection. In Advances in Neural Information Processing Systems, 1070–1078.
- Xiang, Z. J., and Ramadge, P. J. (2012, March). Fast lasso screening tests based on correlations. 2012 IEEE International Conference on Acoustics, Speech and Signal Processing (ICASSP), 2137–2140.
- Wang, J., Zhou, J., Liu, J., Wonka, P., and Ye, J. (2014). A safe screening rule for sparse logistic regression. In Advances in Neural Information Processing Systems, 1053–1061.
Report bugs
Open an issue or send an email to Patrick Breheny at patrick-breheny@uiowa.edu.