To find the position of the max or min in R vector you just have to do the command:

### Description

Determines the location, i.e., index of the (first) minimum or maximum of a numeric (or logical) vector.

### Usage

which.min(x) which.max(x)

To find the position of the max or min in R vector you just have to do the command:

Determines the location, i.e., index of the (first) minimum or maximum of a numeric (or logical) vector.

which.min(x) which.max(x)

About the Author

Related Posts