R/OptPath_getter.R
getOptPathParetoFront.Rd
Get indices of pareto front of optimization path.
getOptPathParetoFront(
op,
y.names = op$y.names,
dob = op$env$dob,
eol = op$env$eol,
index = FALSE
)
OptPath
Optimization path.
character
Names of performance measures to construct pareto front for.
Default is all performance measures.
integer
Vector of date-of-birth values to further subset the result.
Only elements with a date-of-birth included in dob
are selected.
Default is all.
integer
Vector of end-of-life values to further subset the result.
Only elements with an end-of-life included in eol
are selected.
Default is all.
(logical(1)
)
Return indices into path of front or y-matrix of nondominated points?
Default is FALSE
.
matrix
| integer
. Either matrix (with named columns) of points of
front in objective space or indices into path for front.
Other optpath:
OptPath
,
addOptPathEl()
,
getOptPathBestIndex()
,
getOptPathCols()
,
getOptPathCol()
,
getOptPathDOB()
,
getOptPathEOL()
,
getOptPathEl()
,
getOptPathErrorMessages()
,
getOptPathExecTimes()
,
getOptPathLength()
,
getOptPathX()
,
getOptPathY()
,
setOptPathElDOB()
,
setOptPathElEOL()
ps = makeParamSet(makeNumericParam("x"))
op = makeOptPathDF(par.set = ps, y.names = c("y1", "y2"), minimize = c(TRUE, TRUE))
addOptPathEl(op, x = list(x = 1), y = c(5, 3))
addOptPathEl(op, x = list(x = 2), y = c(2, 4))
addOptPathEl(op, x = list(x = 3), y = c(9, 4))
addOptPathEl(op, x = list(x = 4), y = c(4, 9))
as.data.frame(op)
#> x y1 y2 dob eol
#> 1 1 5 3 1 NA
#> 2 2 2 4 2 NA
#> 3 3 9 4 3 NA
#> 4 4 4 9 4 NA
getOptPathParetoFront(op)
#> y1 y2
#> 1 5 3
#> 2 2 4
getOptPathParetoFront(op, index = TRUE)
#> [1] 1 2