frontier: Find efficient frontier

Description Usage Arguments Value Author(s) References Examples

View source: R/frontier.R

Description

A predicate that is TRUE if a point is on the efficient frontier.

Usage

1

Arguments

...

coordinates to scan

Value

logical vector, TRUE if point is on efficient frontier

Author(s)

Neal Fultz

References

https://stackoverflow.com/a/36209989/986793

Examples

1
2
3
4
5
6
7
df <- data.frame(x=rnorm(100), y=rnorm(100))
plot(df)
points(subset(df, frontier(x,y)), col='red', pch=15)
points(subset(df, frontier(-x,y)), col='green', pch=15)
points(subset(df, frontier(x,-y)), col='blue', pch=15)
points(subset(df, frontier(-x,-y)), col='orange', pch=15)
 

stackoverflow documentation built on Jan. 10, 2020, 9:07 a.m.