wq: Empirical weighted quantile

Description Usage Arguments Value References Examples

View source: R/distrr_funs.R

Description

Empirical weighted quantile

Usage

1
wq(x, weights, probs = c(0.5))

Arguments

x

A numeric vector

weights

A vector of (positive) sample weights

probs

a numeric vector with the desired quantile levels (default 0.5, the median)

Value

The weighted quantile (a numeric vector)

References

Ferrez, J., Graf, M. (2007). Enqu<c3><a8>te suisse sur la structure des salaires. Programmes R pour l'intervalle de confiance de la m<c3><a9>diane. (Rapport de m<c3><a9>thodes No. 338-0045). Neuch<c3><a2>tel: Office f<c3><a9>d<c3><a9>ral de statistique.

Examples

1
wq(x = rnorm(100), weights = runif(100))

distrr documentation built on Sept. 8, 2017, 5:04 p.m.