Learn R Programming

ccaPP (version 0.1.1)

fastMedian: Fast implementation of the median

Description

Compute the sample median with a fast C++ implementation.

Usage

fastMedian(x)

Arguments

x
a numeric vector.

Value

  • The sample median.

See Also

fastMAD, median

Examples

Run this code
set.seed(1234)  # for reproducibility
x <- rnorm(100)
fastMedian(x)

Run the code above in your browser using DataLab