plugin.select: Plug-in Bandwidth Selection for Local Polynomial Estimation

Description Usage Arguments Details Value References See Also Examples

View source: R/plugin.select.R

Description

Select the plug-in bandwidth described in Benhenni and Degras (2011) for the local polynomial estimation of a mean function and its first derivative based on functional data.

Usage

1
plugin.select(x, y, drv = 0L, degree = drv+1L, gridsize = length(x), ...) 

Arguments

x

numeric vector of x data. This observation grid must be uniform and missing values are not accepted.

y

matrix or data frame with functional observations (= curves) stored in rows. The number of columns of y must match the length of x. Missing values are not accepted.

drv

order of the derivative to estimate. Must be 0 or 1.

degree

degree of local polynomial used. Must equal drv or drv+1.

gridsize

the size of the grid over which the mean function is to be estimated. Defaults to length(x).

...

additional arguments to pass to the optimizer of the CV score.

Details

The plug-in method should not be used with small data sets, since it is based on asymptotic considerations and requires reasonably accurate estimates of derivatives of the mean and covariance functions. Both the number of observed curves and observation points should be moderate to large. The plug-in bandwidth is designed to minimize the asymptotic mean integrated squared estimation error

AMISE(h) = integral of (μ(t) - μ.hat(t;h))^2,

where μ(t) is the mean function and mu.hat(t;h) is a local polynomial estimator with kernel bandwidth h. The expression of the plug-in bandwidth can be found in Benhenni and Degras (2011).

Value

the plug-in bandwidth.

References

Benhenni, K. and Degras, D. (2011). Local polynomial estimation of the average growth curve with functional data. http://arxiv.org/abs/1107.4058

See Also

cv.select

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
## Not run: 
## Phoneme data
data(phoneme)
classes <- phoneme[,151]
phoneme <- phoneme[,-151]
freq    <- 1:150
plugin.bandwidth  <- numeric(5) 
cv.bandwidth  <- numeric(5)  # compare with cross-validation
for (i in 1:5) {
  plugin.bandwidth[i] <- plugin.select(x = freq, y = phoneme[classes == i, ],
                          drv = 0, degree = 1) 
  cv.bandwidth[i]     <- cv.select(x = freq, y = phoneme[classes == i, ], 
                          degree = 1)
}

round(cbind(plugin.bandwidth, cv.bandwidth), 4)


## End(Not run)

SCBmeanfd documentation built on May 2, 2019, 4:19 a.m.