Learn R Programming

baggingbwsel (version 1.1)

hboot_bag: Bagging bootstrap bandwidth selector for Parzen-Rosenblatt estimator

Description

Bagging bootstrap bandwidth selector for Parzen-Rosenblatt estimator

Usage

hboot_bag(
  x,
  m = n,
  N = 1,
  nb = 1000L,
  g,
  lower,
  upper,
  ncores = parallel::detectCores(logical = FALSE)
)

Value

Bagged CV bandwidth.

Arguments

x

Vector. Sample.

m

Positive integer. Size of the subsamples.

N

Positive integer. Number of subsamples.

nb

Positive integer. Number of bins.

g

Positive real number. Pilot bandwidth.

lower

Positive real number. Range over which to minimize, left bound.

upper

Positive real number. Range over which to minimize, right bound.

ncores

Positive integer. Number of cores with which to parallelize the computations.

Details

Bagging bootstrap bandwidth selector for the Parzen-Rosenblatt estimator.

Examples

Run this code
set.seed(1)
x <- rnorm(10^5)
hboot_bag(x, 5000, 10, 1000, lower=0.001, upper=1, ncores=2)

Run the code above in your browser using DataLab