smooth5vec | R Documentation |
This function computes the smoothed Indicator function I[x < const] using a 5th order polynomial.
If |x - const| > eps then the result is the same as the indicator function I[x < const] (either 0 or 1). For |x - const| < eps, it is a 5th order polynomial.
eps
is a scalar, must > 0. It is the smoothing window width.
smooth5vec(x, const, eps=0.05)
x |
a vector of observations, length m, for the first sample. |
const |
a single number. |
eps |
The smoothing window width, must be >0. Ideally, this should be sample size dependent. |
This function is twice continuously differenciable, smoother than smooth3vec
.
It is listed here because the user may need extra smoothness (compare to smooth3vec
)
and may find it useful elsewhere.
smooth5vec
returns a vector of length=length(x). The entry
of the vector are smoothed values of I[x[i] < const].
Mai Zhou <maizhou@gmail.com>.
Zhao, Y., Ding, X. and Zhou (2021). Confidence Intervals of AUC and pAUC by Empirical Likelihood. Tech Report. https://www.ms.uky.edu/~mai/research/eAUC1.pdf
y <- c(10, 209, 273, 279, 324, 391, 566, 785)
x <- c(21, 38, 39, 51, 77, 185, 240, 289, 524)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.