Learn R Programming

gaselect R package

This R package implements a genetic algorithm (GA) for variable selection as described in Kepplinger, D., Filzmoser, P., and Varmuza, K. (2017). Variable selection with genetic algorithms using repeated cross-validation of PLS regression models as fitness measure. https://arxiv.org/abs/1711.06695.

Installation

To install the latest release from CRAN, run the following R code in the R console:

install.packages('gaselect')

The most recent stable version as well as the developing version might not yet be available on CRAN. These can be directly installed from github using the devtools package:

# Install the most recent stable version:
install_github('dakep/gaselect')
# Install the (unstable) develop version:
install_github('dakep/gaselect', ref = 'develop')

Copy Link

Version

Install

install.packages('gaselect')

Monthly Downloads

308

Version

1.0.25

License

GPL (>= 2)

Issues

Pull Requests

Stars

Forks

Maintainer

David Kepplinger

Last Published

January 8th, 2026

Functions in gaselect (1.0.25)

subsets

Get the found variable subset(s)
toCControlList

Transform the object to a list
trueFitnessVal

Get the transformed fitness values
evaluatorPLS

PLS Evaluator
formatSegmentation

Format the raw segmentation list returned from the C++ code into a usable list
getEvalFun

Get the evaluation function from a GenAlgUserEvaluator
evaluatorUserFunction

User Defined Evaluator
evaluate

Evaluate the fitness of variable subsets
GenAlgPLSEvaluator-class

PLS Evaluator
GenAlgControl-class

Control class for the genetic algorithm
evaluatorLM

LM Evaluator
GenAlgUserEvaluator-class

User Function Evaluator
genAlgControl

Set control arguments for the genetic algorithm
GenAlgFitEvaluator-class

Fit Evaluator
genAlg

Genetic algorithm for variable subset selection
fitness

Get the fitness of a variable subset
GenAlg-class

Result of a genetic algorithm run
GenAlgEvaluator-class

Evaluator Base Class
fitnessEvolution

Get the evolution of the fitness
evaluatorFit

Fit Evaluator
GenAlgLMEvaluator-class

LM Evaluator
validData

Check if the data is valid for the evaluator