Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR R

r mode

find_mode <- function(x) {
  u <- unique(x)
  tab <- tabulate(match(x, u))
  u[tab == max(tab)]
}
Source by www.statology.org #
 
PREVIOUS NEXT
Tagged: #mode
ADD COMMENT
Topic
Name
4+6 =