Feature selection with the R package MXM

Michail Tsagris, Ioannis Tsamardinos

Abstract

Feature selection is a cornerstone of high-dimensional data analysis, yet many existing tools are limited to specific data distributions or small datasets. This paper introduces the R package MXM (Mens ex Machina), a comprehensive suite for feature selection designed to handle a wide array of data types, including survival, longitudinal, and high-volume data. By implementing constraint-based and residual-based algorithms such as MMPC, SES, FBED, and gOMP, MXM provides a flexible architecture for identifying statistically significant predictors. Notably, the SES algorithm allows for the discovery of multiple statistically equivalent feature sets, offering deeper biological insights than traditional single-output methods.

Introduction

In the era of "big data," particularly within bioinformatics and clinical research, the "curse of dimensionality" presents a significant challenge. Feature selection (FS) is the process of identifying a minimal subset of variables that retains the maximum predictive power for a target outcome. Effective FS reduces noise, improves model interpretability, and mitigates overfitting. However, the landscape of FS tools in the R ecosystem is often fragmented, with many packages specializing in only a narrow range of data types or failing to scale with modern dataset sizes.

The Challenge of Heterogeneous Data

Researchers frequently encounter complex data structures that do not fit standard binary or continuous regression models. Examples include "censored" survival times in oncology, repeated measurements in longitudinal studies, or discrete count data in RNA-sequencing. Most existing R packages are "one-trick ponies," forcing users to simplify their data—and potentially lose critical information—to fit the tool's requirements. Furthermore, many algorithms struggle when the dataset exceeds the system's RAM, leading to computational bottlenecks.

Methodological Framework of MXM

The MXM package addresses these gaps by providing a unified, "plug-and-play" framework. It implements several sophisticated algorithms inspired by Bayesian network learning and information theory:

  • Max-Min Parents and Children (MMPC): A constraint-based algorithm that identifies the "neighborhood" of a target variable by testing for conditional independence.
  • Statistically Equivalent Signatures (SES): A flagship feature of MXM, SES identifies multiple sets of features that are statistically interchangeable. This is particularly valuable in fields like genomics, where different genes may belong to the same pathway and thus carry redundant predictive information.
  • Forward-Backward with Early Dropping (FBED): Optimized for speed, FBED is designed to handle very large datasets by quickly discarding irrelevant features before performing more intensive statistical tests.
  • Generalized Orthogonal Matching Pursuit (gOMP): A fast, residual-based approach tailored for high-volume data, providing a parsimonious set of predictors.

The package's architecture allows users to seamlessly swap regression models (e.g., Poisson, Cox, Logistic) and statistical tests (e.g., Likelihood-ratio, Wald, or permutation-based) to match their specific data characteristics.

Demonstrated Versatility Across Biological Datasets

The authors validated MXM using five distinct real-world biological datasets, showcasing its ability to handle diverse challenges:

  1. Breast Cancer Survival: Time-to-event data (295 samples, 70 features).
  2. Breast Cancer Case-Control: High-dimensional binary data (285 samples, 17,187 gene expressions).
  3. Skeletal Muscle (GSE9105): Longitudinal/repeated measures (12 individuals, 3 time points, 22,283 features).
  4. Human Cerebral Organoids: Continuous RNA-seq data (729 samples, 58,037 features).
  5. RNA-seq Count Data (GSE47774): Discrete count data (256 samples, 43,919 features).

Key Insights and Innovations

  • Beyond the "Best" Feature Set: Traditional FS methods often return a single list of predictors. MXM’s SES algorithm recognizes that in complex biological systems, multiple distinct gene sets might provide identical predictive power. This prevents researchers from overlooking biologically relevant variables that happen to be statistically redundant with the "top" picks.
  • High-Volume Data Management: MXM integrates with memory-efficient packages like bigmemory, allowing it to process datasets that would typically exceed standard RAM limits.
  • Robustness in Small Samples: For studies with few observations but many features (e.g., n < 100, p > 10,000), MXM offers permutation-based tests that provide more reliable results than standard large-sample approximations.

Performance Benchmarks

A comparative survey of 184 R packages revealed that while 95% supported only one or two target variable types, MXM was unique in its ability to handle all eight categories tested, including multivariate and ordinal data. In practical applications, the FBED algorithm demonstrated remarkable efficiency, narrowing 58,037 features down to 63 significant predictors in the cerebral organoid dataset. The gOMP algorithm proved even more selective, identifying just 8 key features while maintaining a high adjusted $R^2$.

Limitations and Future Work

While MXM is a powerful tool, it is computationally more intensive than simpler methods like LASSO due to the number of regression models it fits. Ongoing development aims to port core functions to C++ for improved performance. Future updates are expected to include support for time-series data, multi-state survival models, and expanded visualization tools for feature networks.

Summary updated

BibTeX
@inproceedings{tsagris2019feature,
  author = {Michail Tsagris and Ioannis Tsamardinos},
  title = {{Feature selection with the R package MXM}},
  booktitle = {F1000Research},
  year = {2019},
  doi = {10.12688/f1000research.16216.2},
}
Figure