How to return 5 topmost values from vector in R?

Viewed 102221

I have a vector and I'm able to return highest and lowest value, but how to return 5 topmost values? Is there a simple one-line solution for this?

4 Answers
Related