Fastest way to find second (third...) highest/lowest value in vector or column
Posted
by jorgusch
on Stack Overflow
See other posts from Stack Overflow
or by jorgusch
Published on 2010-03-16T09:54:16Z
Indexed on
2010/03/16
9:56 UTC
Read the original article
Hit count: 136
r
|best-practices
Hello,
R offers max and min, but I do not see a really fast way to find the another value in the order apart from sorting the whole vector and than picking value x from this vector.
Is there a faster way to get the second highest value (e.g.)?
Thanks
© Stack Overflow or respective owner