This function returns a list of values for the control parameters of the functions of the package that use the bootstrap or cross-validation.
controlpars(B = 999L, hbound = c(0.1, 3), hl = 100L, hsave =
FALSE, nnfrac = 0.25, fpilot = NULL, qt = 0.75, hsmooth = 1L, …)
An integer giving the number of bootstrap resamples.
A numeric vector of length 2 specifying the minimum (default, 0.1) and maximum (default, 3), respectively, of the initial grid of bandwidths as a multiple of the standardized interquartile range of the covariate values.
A numeric value giving the length of the initial grid of bandwidths. The default is 100.
A logical value specifying if the grids of bandwidths
must be saved as a component of the list returned by the
berancv
, latencyboot
and probcurehboot
functions. The default is FALSE
.
A numeric value giving the fraction of the sample size that determines the order of the nearest neighbor used when choosing the pilot bandwidth. The default is 0.25.
A function name or NULL
. If NULL
, the
default, the hpilot
function is used for computing a pilot
bandwidth in case that one is needed. If not NULL
, it must be
the name of a user-defined function (given as a function name or as
a character string). This function must necessarily have an argument
x0
, playing the same role than in hpilot
, and must
return a value of the same length than x0
. If fpilot
has more arguments, they are passed through the …
argument (see below).
In bandwidth selection for the latency estimator (see
latencyhboot
), a numeric value specifiying the order of a
quantile of the observed times. It determines the right boundary
of the integration interval in the computation of the ISE (the left
boundary is 0). The default is 0.75 (third quartile).
An integer. Its value controls whether the bandwidths
selected by the latencyhboot
and probcurehboot
and
berancv
function should be smoothed, and, if so, the degree
of smoothing. The smoothing consists in computing a centered moving
average of the unsmoothed vector of bandwidths returned by default
by latencyhboot
and probcurehboot
. The value of
hsmooth
is the number of terms used to compute the
average. The default is 1L, which means that no smoothing is done.
Arguments of fpilot
, if fpilot
is not
NULL
.
A list whose components are the arguments of the function, their defaults being replaced with the values the function was called with.
The output of controlpars
is a list of control
parameters required by the package functions which use the bootstrap
or cross-validation. This is mainly the case of the berancv
function, which computes a cross-validation bandwidth for Beran's
estimator of survival, and of the latencyhboot
and
probcurehboot
functions, which compute the bootstrap bandwidth
selectors of the estimators of the latency and the probability of
cure, respectively. Since these functions are indirectly called by,
respectively, the beran
, latency
and probcure
functions when their h
argument is missing, the output of
controlpars
is also the expected (and default) way of passing
to them the parameters for bandwidth selection.
Additionally, controlpars
is used by beran
,
latency
and probcure
to set the number of bootstrap
resamples and the value of nnfrac
(see above) when confidence
intervals are computed. The testcov
function also uses it for
setting the number of bootstrap resamples.
beran
,berancv
,
hpilot
, latency
,
latencyhboot
, probcure
,
probcurehboot
,testcov