Diff of /which.is.max.R [000000] .. [81de4e]

Switch to unified view

a b/which.is.max.R
1
which.is.max <- function (x) 
2
{
3
  y <- seq(length(x))[x == max(x)]
4
  if (length(y) > 1) 
5
    y <- sample(y, 1)
6
  y
7
}