I'm interesting in evolutionary algorithms. I have tested genetic algorithms with R but has someone tried with genetic programming? Do you know, if there are code somewhere written in R.
-
7Have you posted the same message in April, 2007: http://tolstoy.newcastle.edu.au/R/e2/help/07/04/13635.html – Mehper C. Palavuzlar Apr 21 '10 at 08:15
-
`library("sos"); findFn("{genetic algorithm}")` – Ben Bolker Apr 29 '13 at 13:41
3 Answers
I'm not aware of anything on CRAN for genetic programming in particular, although there is some work being done on the problem. In particular, have a look at the RGP package that is still in development.
Otherwise, have a look at the RFreak package, which is a wrapper for the "Free Evolutionary Algorithm Kit".

- 98,550
- 35
- 224
- 217
You might want to have a look at genalg, at GA and at galgo

- 1,141
- 20
- 44
-
1[Genetic algorithms are not Genetic programming!](https://stackoverflow.com/questions/3819977/what-are-the-differences-between-genetic-algorithms-and-genetic-programming) – catastrophic-failure Apr 06 '18 at 23:05
There is a new package available:
gramEvol: Grammatical Evolution for R
A native R implementation of grammatical evolution (GE). GE facilitates the discovery of programs that can achieve a desired goal. This is done by performing an evolutionary optimisation over a population of R expressions generated via a user-defined context-free grammar (CFG) and cost function.
You can find the vignette here:
Grammatical Evolution: A Tutorial using gramEvol
UPDATE: I posted an article on my blog about it:
Symbolic Regression, Genetic Programming… or if Kepler had R.

- 4,202
- 3
- 44
- 68