which.dominated | R Documentation |
Given a matrix with one point per column which.dominated
returns the
column numbers of the dominated points and which.nondominated
the column
numbers of the nondominated points. Function isMaximallyDominated
returns
a logical vector with TRUE
for each point which is located on the last
non-domination level.
which.dominated(x)
which.nondominated(x)
isMaximallyDominated(x)
x |
[ |
[integer
]
data(mtcars)
# assume we want to maximize horsepower and minimize gas consumption
cars = mtcars[, c("mpg", "hp")]
cars$hp = -cars$hp
idxs = which.nondominated(as.matrix(cars))
print(mtcars[idxs, ])
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.