nestedcv: an R package for fast implementation of nested cross-validation with embedded feature selection designed for transcriptomics and high-dimensional data

Myles J Lewis, Athina Spiliopoulou, Katriona Goldmann, Costantino Pitzalis, Paul McKeigue, Michael R Barnes

Research output: Contribution to journalArticlepeer-review

Abstract / Description of output

Motivation: Although machine learning models are commonly used in medical research, many analyses implement a simple partition into training data and hold-out test data, with cross-validation (CV) for tuning of model hyperparameters. Nested CV with embedded feature selection is especially suited to biomedical data where the sample size is frequently limited, but the number of predictors may be significantly larger (P ≫ n). Results: The nestedcv R package implements fully nested k × l-fold CV for lasso and elastic-net regularized linear models via the glmnet package and supports a large array of other machine learning models via the caret framework. Inner CV is used to tune models and outer CV is used to determine model performance without bias. Fast filter functions for feature selection are provided and the package ensures that filters are nested within the outer CV loop to avoid information leakage from performance test sets. Measurement of performance by outer CV is also used to implement Bayesian linear and logistic regression models using the horseshoe prior over parameters to encourage a sparse model and determine unbiased model accuracy.

Original languageEnglish
Article numbervbad048
Pages (from-to)vbad048
JournalBioinformatics Advances
Volume3
Issue number1
DOIs
Publication statusPublished - 13 Apr 2023

Fingerprint

Dive into the research topics of 'nestedcv: an R package for fast implementation of nested cross-validation with embedded feature selection designed for transcriptomics and high-dimensional data'. Together they form a unique fingerprint.

Cite this