Bandwidth Selection by Pilot Estimation of Derivatives

DESCRIPTION:

Uses the method of Sheather & Jones (1991) to select the bandwidth of a Gaussian kernel density estimator.

USAGE:

bandwidth.sj(x, nb=1000, lower, upper, method=c("ste", "dpi"), freq) 

REQUIRED ARGUMENTS:

x
a numeric vector

OPTIONAL ARGUMENTS:

nb
number of bins to use.
upper, lower
range over which to search for solution if method = "ste".
method
Either "ste" ("solve-the-equation") or "dpi" ("direct plug-in").
freq
Vector the same length as x, giving frequencies (positive integers). If supplied, x is replaced with rep(x, freq).

VALUE:

a bandwidth.

DETAILS:

This function is based upon the function width.SJ in Venables and Ripley (1997).

REFERENCES:

Scott, D. W. (1992) Multivariate Density Estimation: Theory, Practice, and Visualization. Wiley.

Sheather, S. J. and Jones, M. C. (1991) A reliable data-based bandwidth selection method for kernel density estimation. Journal of the Royal Statistical Society series B 53, 683-690.

Venables, W. N. and Ripley, B. D. (1997) Modern Applied Statistics with S-PLUS, Second Edition. Springer.

Wand, M. P. and Jones, M. C. (1995) Kernel Smoothing. Chapman & Hall.

SEE ALSO:

, , , ,