Error density estimation in a nonparametric functional regression model with functional predictor and scalar response is considered. The unknown error density is approximated by a mixture of Gaussian densities with means being the individual residuals, and variance as a constant parameter. This proposed mixture error density has a form of a kernel density estimator of residuals, where the regression function is estimated by the functional Nadaraya–Watson estimator. A Bayesian bandwidth estimation procedure that can simultaneously estimate the bandwidths in the kernel-form error density and the functional Nadaraya–Watson estimator is proposed. A kernel likelihood and posterior for the bandwidth parameters are derived under the kernel-form error density. A series of simulation studies show that the proposed Bayesian estimation method performs on par with the functional cross validation for estimating the regression function, but it performs better than the likelihood cross validation for estimating the regression error density. The proposed Bayesian procedure is also applied to a nonparametric functional regression model, where the functional predictors are spectroscopy wavelengths and the scalar responses are fat/protein/moisture content, respectively.
- Functional Nadaraya–Watson estimator
- Kernel density estimation
- Markov chain Monte Carlo
- Mixture error density