Med: Calculate lower and upper median

View source: R/misc.R

MedR Documentation

Calculate lower and upper median

Description

Calculates the lower and and median of a vector as proposed in Comment 4.2 in the paper.

Usage

Med(x)

Arguments

x

A numeric vector.

Value

A list with the upper and lower median and the Med statistic (which is their mean).

References

Chernozhukov V., Demirer M., Duflo E., Fernández-Val I. (2020). “Generic Machine Learning Inference on Heterogenous Treatment Effects in Randomized Experiments.” arXiv preprint arXiv:1712.04802. URL: https://arxiv.org/abs/1712.04802.

Examples

set.seed(1)
x <- runif(100)
Med(x)


GenericML documentation built on June 18, 2022, 9:09 a.m.

Related to Med in GenericML...