mode: Calculate the Statistical Mode

View source: R/utils.R

modeR Documentation

Calculate the Statistical Mode

Description

This function returns the most frequent (modal) value in a vector. If there are multiple values with the same highest frequency, it returns the first one encountered.

Usage

mode(x)

Arguments

x

A vector of numeric, character, or factor values.

Value

A single value representing the mode of the input vector.


Qploidy documentation built on June 8, 2025, 10 a.m.