#// **********************************************************************************************
#// Mode.R
#// **********************************************************************************************
#//
#//
#// **********************************************************************************************
#// @Maintainer: Justin Sing
#// @Author: Justin Sing
#' @export
#' @title Mode
#' @description Get the mode for a vector
#'
#' @param x A vector
#' @return The mode of the vector
#'
Mode <- function(x) {
ux <- unique(x)
ux[which(tabulate(match(x, ux)) == max(tabulate(match(x, ux))))]
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.