sd_via_median_estimator: Compute standard deviation via median estimator.

View source: R/sd_via_median_estimator.R

sd_via_median_estimatorR Documentation

Compute standard deviation via median estimator.

Description

Compute standard deviation via median estimator. Please refer to formula #2 in Engbert & Kliegl (2003). Falls back on mean estimator, if computed standard deviation is smaller than .Machine$double.eps. Raises an error if the results using the mean estimator is still smaller than .Machine$double.eps.

Usage

sd_via_median_estimator(x, na.rm = FALSE)

Arguments

x

Numeric values

na.rm

Whether to exclude NA values, defaults to FALSE.

Value

float

Examples

sd_via_median_estimator(rnorm(100))

saccadr documentation built on Sept. 8, 2023, 5:13 p.m.