Package: ecr 2.1.1

ecr: Evolutionary Computation in R

Framework for building evolutionary algorithms for both single- and multi-objective continuous or discrete optimization problems. A set of predefined evolutionary building blocks and operators is included. Moreover, the user can easily set up custom objective functions, operators, building blocks and representations sticking to few conventions. The package allows both a black-box approach for standard tasks (plug-and-play style) and a much more flexible white-box approach where the evolutionary cycle is written by hand.

Authors:Jakob Bossek [aut, cre, cph], Michael H. Buselli [ctb, cph], Wessel Dankers [ctb, cph], Carlos M. Fonseca [ctb, cph], Manuel Lopez-Ibanez [ctb, cph], Luis Paquete [ctb, cph], Joshua Knowles [ctb, cph], Eckart Zitzler [ctb, cph], Olaf Mersmann [ctb]

ecr_2.1.1.tar.gz
ecr_2.1.1.zip(r-4.7)ecr_2.1.1.zip(r-4.6)ecr_2.1.1.zip(r-4.5)
ecr_2.1.1.tgz(r-4.6-x86_64)ecr_2.1.1.tgz(r-4.6-arm64)ecr_2.1.1.tgz(r-4.5-x86_64)ecr_2.1.1.tgz(r-4.5-arm64)
ecr_2.1.1.tar.gz(r-4.7-arm64)ecr_2.1.1.tar.gz(r-4.7-x86_64)ecr_2.1.1.tar.gz(r-4.6-arm64)ecr_2.1.1.tar.gz(r-4.6-x86_64)
ecr_2.1.1.tgz(r-4.6-emscripten)
manual.pdf |manual.html
card.svg |card.png
ecr/json (API)
NEWS

# Install 'ecr' in R:
install.packages('ecr', repos = c('https://jakobbossek.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/jakobbossek/ecr2/issues

Uses libs:
  • c++– GNU Standard C++ Library v3
Datasets:

On CRAN:

Conda:

combinatorial-optimizationevolutionary-algorithmevolutionary-algorithmsevolutionary-strategygenetic-algorithm-frameworkmetaheuristicsmulti-objective-optimizationoptimizationoptimization-frameworkcpp

7.71 score 43 stars 2 packages 99 scripts 343 downloads 129 exports 87 dependencies

Last updated from:ae5032dbd3. Checks:13 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-arm64OK189
linux-devel-x86_64OK209
source / vignettesOK292
linux-release-arm64OK201
linux-release-x86_64OK214
macos-release-arm64OK98
macos-release-x86_64OK318
macos-oldrel-arm64OK144
macos-oldrel-x86_64OK217
windows-develOK153
windows-releaseOK139
windows-oldrelOK152
wasm-releaseOK147

Exports:%dominates%%isDominatedBy%addAllGroupaddUnionGroupapproximateIdealPointapproximateNadirPointapproximateRefPointsapproximateRefSetsasemoacategorizecomputeAverageHausdorffDistancecomputeCrowdingDistancecomputeDistanceFromPointToSetOfPointscomputeDominanceRankingcomputeGenerationalDistancecomputeHVcomputeHVContrcomputeIndicatorscomputeInvertedGenerationalDistancedominateddominatesdoNondominatedSortingecremoaIndCemoaIndDeltaemoaIndDeltapemoaIndEpsemoaIndGDemoaIndHVemoaIndIGDemoaIndM1emoaIndMDemoaIndONVGemoaIndR1emoaIndR2emoaIndR3emoaIndSPevaluateFitnessexplodefilterDuplicatedgengenBingenerateOffspringgeneratesMultipleChildrengenPermgenRealgetFrontgetIndividualsgetNumberOfChildrengetNumberOfParentsNeededForMatinggetPopulationsgetSizegetStatisticsgetSupportedRepresentationsimplodeinitECRControlinitLoggerinitParetoArchiveinitPopulationis.supportedisDominatedisEcrOperatorisMaximallyDominatedmakeECRMonitormakeEMOAIndicatormakeMutatormakeOperatormakeOptimizationTaskmakeRecombinatormakeSelectormakeTerminatormutatemutBitflipmutGaussmutInsertionmutInversionmutJumpmutPolynomialmutScramblemutSwapmutUniformniceCellFormaternondominatednormalizensga2plotDistributionplotFrontplotHeatmapplotScatter2dplotScatter3dplotStatisticsrecCrossoverrecIntermediaterecombinaterecOXrecPMXrecSBXrecUnifCrossoverreduceToSingleDataFrameregisterECROperatorreplaceMuCommaLambdareplaceMuPlusLambdaselDomHVselDomNumberPlusHVselectForMatingselectForSurvivalselGreedyselNondomselRankingselRouletteselSimpleselTournamentsetDominatessetupsetupECRDefaultMonitorsmsemoasortByObjectivestopOnEvalsstopOnItersstopOnMaxTimestopOnOptYtoGGtoLatextoParetoDfupdateLoggerupdateParetoArchivewhich.dominatedwhich.nondominatedwrapChildren

Dependencies:askpassbackportsbase64encBBmiscbslibcachemcheckmateclicpp11crosstalkcurldata.tabledigestdplyrevaluatefarverfastmapfastmatchfontawesomefsgenericsggplot2gluegridExtragtablehighrhtmltoolshtmlwidgetshttrisobandjquerylibjsonlitekableExtraknitrlabelinglaterlazyevallifecyclemagrittrmemoisemimemisc3dopensslotelparallelMapParamHelperspillarpkgconfigplot3Dplot3DrglplotlyplyrpromisespurrrR6rappdirsRColorBrewerRcppRcppArmadilloreshape2rglrlangrmarkdownrstudioapiS7sassscalesscatterplot3dsmoofstringistringrsvglitesyssystemfontstextshapingtibbletidyrtidyselecttinytexutf8vctrsviridisviridisLitewithrxfunxml2yaml

Brief introduction to ecr

Rendered fromintroduction.Rmdusingknitr::rmarkdownon May 25 2026.

Last update: 2019-10-23
Started: 2017-03-29

Multi-Objective Evolutionary Algorithms

Rendered frommultiobjective.Rmdusingknitr::rmarkdownon May 25 2026.

Last update: 2019-10-23
Started: 2019-10-23

Readme and manuals

Help Manual

Help pageTopics
Grouping helpersaddAllGroup addUnionGroup
Reference point approximationsapproximateIdealPoint approximateNadirPoint
Helper function to estimate reference pointsapproximateRefPoints
Helper function to estimate reference set(s)approximateRefSets
Implementation of the NSGA-II EMOA algorithm by Debasemoa
Assign group membership based on another group membershipcategorize
Average Hausdorff Distance computationcomputeAverageHausdorffDistance
Compute the crowding distance of a set of pointscomputeCrowdingDistance
Computes distance between a single point and set of pointscomputeDistanceFromPointToSetOfPoints
Ranking of approximation setscomputeDominanceRanking
Computes Generational DistancecomputeGenerationalDistance
Functions for the calculation of the dominated hypervolume (contribution)computeHV computeHVContr
Computation of EMOA performance indicatorscomputeIndicators
Computes Inverted Generational DistancecomputeInvertedGenerationalDistance
Check for pareto dominancedominated nondominated
Dominance relation check%dominates% %isDominatedBy% dominates isDominated
Fast non-dominated sorting algorithmdoNondominatedSorting
Interface to ecr similar to the optim functionecr
Parallelization in ecrecr_parallelization
Result objectecr_result
EMOA performance indicatorsemoaIndC emoaIndDelta emoaIndDeltap emoaIndEps emoaIndGD emoaIndHV emoaIndIGD emoaIndM1 emoaIndMD emoaIndONVG emoaIndR1 emoaIndR2 emoaIndR3 emoaIndSP
Computes the fitness value(s) for each individual of a given setevaluateFitness
Explode/implode data frame column(s)explode implode
Filter approximation sets by duplicate objective vectorsfilterDuplicated filterDuplicated.data.frame filterDuplicated.ecr_multi_objective_result filterDuplicated.list filterDuplicated.matrix
Helper functions for offspring generationgenerateOffspring mutate recombinate
Does the recombinator generate multiple children?generatesMultipleChildren
Population generatorsgen genBin generators genPerm genReal
Extract fitness values from Pareto archivegetFront
Extract individuals from Pareto archivegetIndividuals
Number of childrengetNumberOfChildren
Number of parents needed for matinggetNumberOfParentsNeededForMating
Access to logged population fitnessgetPopulationFitness
Access to logged populationsgetPopulations
Get size of Pareto-archivegetSize
Access the logged statisticsgetStatistics
Get supported representationsgetSupportedRepresentations
Control object generatorinitECRControl
Initialize a log objectinitLogger
Initialize Pareto ArchiveinitParetoArchive
Helper function to build initial populationinitPopulation
Check if ecr operator supports given representationis.supported
Check if given function is an ecr operatorisEcrOperator
Factory method for monitor objectsmakeECRMonitor
Constructor for EMOA indicatorsmakeEMOAIndicator
Construct a mutation operatormakeMutator
Construct evolutionary operatormakeOperator
Creates an optimization taskmakeOptimizationTask
Construct a recombination operatormakeRecombinator
Construct a selection operatormakeSelector
Generate stopping conditionmakeTerminator
mcMSTmcMST
Bitplip mutatormutBitflip
Gaussian mutatormutGauss
Insertion mutatormutInsertion
Inversion mutatormutInversion
Jump mutatormutJump
Polynomial mutationmutPolynomial
Scramble mutatormutScramble
Swap mutatormutSwap
Uniform mutatormutUniform
Formatter for table cells of LaTeX tablesniceCellFormater
Normalize approximations set(s)normalize
Implementation of the NSGA-II EMOA algorithm by Debnsga2
Plot distribution of EMOA indicatorsplotDistribution
Draw scatterplot of Pareto-front approximationplotFront
Plot heatmapplotHeatmap
Visualize bi-objective Pareto-front approximationsplotScatter2d
Visualize three-objective Pareto-front approximationsplotScatter3d
Generate line plot of logged statisticsplotStatistics
One-point crossover recombinatorrecCrossover
Indermediate recombinatorrecIntermediate
Ordered-Crossover (OX) recombinatorrecOX
Partially-Mapped-Crossover (PMX) recombinatorrecPMX
Simulated Binary Crossover (SBX) recombinatorrecSBX
Uniform crossover recombinatorrecUnifCrossover
Combine multiple data frames into a single data.framereduceToSingleDataFrame
Register operators to control objectregisterECROperator
(mu + lambda) selectionreplace replaceMuCommaLambda replaceMuPlusLambda
Dominated Hypervolume selectorselDomHV
Modified dominated Hypervolume selectorselDomNumberPlusHV
Select individualsselect selectForMating selectForSurvival
Simple selectorselGreedy
Non-dominated sorting selectorselNondom
Rank Selection OperatorselRanking
Roulette-wheel / fitness-proportional selectorselRoulette
Simple (naive) selectorselSimple
k-Tournament selectorselTournament
Check if one set is better than anothersetDominates
Set up parameters for evolutionary operatorsetup
Default monitorsetupECRDefaultMonitor
Implementation of the SMS-EMOA by Emmerich et alsmsemoa
Sort Pareto-front approximation by objectivesortByObjective sortByObjective.data.frame sortByObjective.ecr_multi_objective_result sortByObjective.list sortByObjective.matrix
Stopping conditionsstopOnEvals stopOnIters stopOnMaxTime stopOnOptY stoppingConditions
Transform to long formattoGG
Export results of statistical tests to LaTeX table(s)toLatex toLatex.data.frame toLatex.list
Convert matrix to Pareto front data frametoParetoDf
Fitness transformation / scalingtransformFitness
Update the logupdateLogger
Update Pareto ArchiveupdateParetoArchive
Determine which points of a set are (non)dominatedisMaximallyDominated which.dominated which.nondominated
Wrap the individuals constructed by a recombination operatorwrapChildren