GA v3.2

0

Monthly downloads

0th

Percentile

Genetic Algorithms

Flexible general-purpose toolbox implementing genetic algorithms (GAs) for stochastic optimisation. Binary, real-valued, and permutation representations are available to optimize a fitness function, i.e. a function provided by users depending on their objective function. Several genetic operators are available and can be combined to explore the best settings for the current task. Furthermore, users can define new genetic operators and easily evaluate their performances. Local search using general-purpose optimisation algorithms can be applied stochastically to exploit interesting regions. GAs can be run sequentially or in parallel, using an explicit master-slave parallelisation or a coarse-grain islands approach.

Readme

GA

CRAN\_Status\_Badge CRAN\_MonthlyDownloads

An R package for stochastic optimisation using Genetic Algorithms.

The GA package provides a flexible general-purpose set of tools for implementing genetic algorithms search in both the continuous and discrete case, whether constrained or not. Users can easily define their own objective function depending on the problem at hand. Several genetic operators are available and can be combined to explore the best settings for the current task. Furthermore, users can define new genetic operators and easily evaluate their performances. Local search using general-purpose optimisation algorithms can be applied stochastically to exploit interesting regions. GAs can be run sequentially or in parallel, using an explicit master-slave parallelisation or a coarse-grain islands approach.

Installation

You can install the released version of GA from CRAN:

install.packages("GA")

or the development version from GitHub:

# install.packages("devtools")
devtools::install_github("luca-scr/GA", build_vignettes = TRUE)

Usage

Usage of the main functions and several examples are included in the papers shown in the references section below.

For an intro see the vignette A quick tour of GA, which is available as

vignette("GA")

The vignette is also available in the Get Started section on the GitHub web page of the package at http://luca-scr.github.io/GA/.

References

Scrucca, L. (2013) GA: A Package for Genetic Algorithms in R. Journal of Statistical Software, 53(4), 1-37. https://www.jstatsoft.org/article/view/v053i0

Scrucca, L. (2017) On some extensions to GA package: hybrid optimisation, parallelisation and islands evolution. The R Journal, 9(1), 187–206. https://journal.r-project.org/archive/2017/RJ-2017-008

Functions in GA

Name Description
ga_Population Population initialization in genetic algorithms
numericOrNA-class Virtual Class "numericOrNA" - Simple Class for sub-assignment Values
ga Genetic Algorithms
palettes Colours palettes
GA-internal Internal GA functions
parNames-methods Parameters or decision variables names from an object of class ga-class.
gaControl A function for setting or retrieving defaults genetic operators
binary2decimal Binary encoding of decimal numbers and vice versa.
persp3D Perspective plot with colour levels
gaMonitor Monitor genetic algorithm evolution
plot.de-method Plot of Differential Evolution search path
GA-package Genetic Algorithms
plot.ga-method Plot of Genetic Algorithm search path
de Differential Evolution via Genetic Algorithms
gaSummary Summarize genetic algorithm evolution
ga_Selection Selection operators in genetic algorithms
ga_Crossover Crossover operators in genetic algorithms
binary2gray Gray encoding for binary strings
plot.gaisl-method Plot of Islands Genetic Algorithm search path
gaisl-class Class "gaisl"
gaisl Islands Genetic Algorithms
ga_pmutation Variable mutation probability in genetic algorithms
summary.ga-method Summary for Genetic Algorithms
summary.gaisl-method Summary for Islands Genetic Algorithms
summary.de-method Summary for Differential Evolution
de-class Class "de"
ga-class Class "ga"
ga_Mutation Mutation operators in genetic algorithms
No Results!

Vignettes of GA

Name
GA.Rmd
vignette.css
vignette2.css
No Results!

Last month downloads

Details

Date 2019-01-10
LinkingTo Rcpp, RcppArmadillo
License GPL (>= 2)
VignetteBuilder knitr
URL https://luca-scr.github.io/GA/
BugReports https://github.com/luca-scr/GA/issues
Repository CRAN
ByteCompile true
LazyData yes
RoxygenNote 6.1.1
NeedsCompilation yes
Packaged 2019-01-10 10:53:43 UTC; luca
Date/Publication 2019-01-10 12:00:03 UTC

Include our badge in your README

[![Rdoc](http://www.rdocumentation.org/badges/version/GA)](http://www.rdocumentation.org/packages/GA)