Skip to contents

P(x) = sum w_j Y_j / sum w_j with w_i = I(|z_i - z| < h) exp(-(z_i - z)^2) on the median/MADN standardized scale.

Usage

LogRSM(x, y, pts = x, h = 1.2)

Arguments

x

Predictor.

y

Binary outcome (0/1).

pts

Evaluation points (default x).

h

Window half-width.

Value

list(phat, pts).

References

Wilcox, R. R. (2017). Modern Statistics for the Social and Behavioral Sciences, 2nd ed. Eq (15.15).

Examples

LogRSM(1:6, c(0, 0, 1, 0, 1, 1), pts = 3.5)$phat
#> [1] 0.5