powered by
Something similar to Python's argmax.
argmax(x, decreasing = TRUE)
The maximum value and its index.
Object to have its maximum found
Logical value indicating whether x should be ordered in decreasing order. Default is TRUE. Setting this to FALSE would find the minimum.
x
TRUE
FALSE
library(tsgc) data(gauteng,package="tsgc") argmax(gauteng)
Run the code above in your browser using DataLab