Description Usage Arguments Details Value See Also Examples
Minimises the leave-one-out estimate of root mean-squared error to find find the "optimal" bandwidth for smoothing.
1 |
x |
condensed summary to smooth |
h_init |
initial values of bandwidths to start search out. If not specified defaults to 5 times the binwidth of each variable. |
... |
other arguments (like |
tol |
numerical tolerance, defaults to 1%. |
control |
additional control parameters passed on to |
L-BFGS-B optimisation is used to constrain the bandwidths to be greater than the binwidths: if the bandwidth is smaller than the binwidth it's impossible to compute the rmse because no smoothing occurs. The tolerance is set relatively high for numerical optimisation since the precise choice of bandwidth makes little difference visually, and we're unlikely to have sufficient data to make a statistically significant choice anyway.
a single numeric value representing the bandwidth that minimises
the leave-one-out estimate of rmse. Vector has attributes
evaluations
giving the number of times the objective function
was evaluated. If the optimisation does not converge, or smoothing is not
needed (i.e. the estimate is on the lower bounds), a warning is thrown.
Other bandwidth estimation functions: h_grid
;
rmse_cv
, rmse_cvs
1 2 3 4 5 6 7 8 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.