This function computes the midrange score, i.e. the average of the lowest and highest values in a set of data. See the Details section below for further information.
Value
A numerical value representing the computed measure.
A default NA
value is returned if the score can't be
computed.
Details
The midrange score is a measure of central tendency like the mean, median, and mode. However, it is more prone to bias than these other measures because it relies solely upon the two most extreme scores, which could potentially be outliers.
Examples
x = c(0,1,1,2,3,3,3,100,NA)
midrange(x = x, na.rm = TRUE)
#> [1] 50