Determines the location, i.e., index of the maximum of a numeric (or logical) vector. In case of tie, the index is selected randomly.

which.max.random(vec)

Arguments

vec

Numeric (logical, integer or double) vector.

Value

Index of the maximum value.