find mode of a vector