Linton and Nielsen (1995): the pilot is the full-dimensional
Nadaraya-Watson estimate \(\hat g\) with a product Gaussian kernel, and
component \(j\) averages it over the observed values of the other
covariates, \(\hat m_j(t) = n^{-1} \sum_k \hat g(t, X_{k,-j}) - \bar Y\),
evaluated on an equally spaced grid. Fitted values interpolate each
component linearly. Identical to the Python arm morie.fn.admod.admod.
Usage
admod(Y, X, bandwidth = NULL, grid_size = 50)
Arguments
- Y
Numeric outcome vector.
- X
Covariate matrix (a vector is one covariate).
- bandwidth
Kernel bandwidth used in every direction; default
\(1.06 \bar s n^{-1/(4+p)}\) with \(\bar s\) the mean of the column
standard deviations (divisor n).
- grid_size
Grid points per component.
Value
A list with intercept, components (each a list with
x_grid and m_hat), residuals, bandwidth,
n, p and method.
References
Linton, O. and Nielsen, J. P. (1995). A kernel method of
estimating structured nonparametric regression based on marginal
integration. Biometrika 82, 93-100.
Examples
X <- cbind(c(0, 1, 2, 3, 4, 5), c(1, 0, 2, 1, 3, 2))
admod(c(1, 1.5, 3.2, 3.9, 6.1, 6), X, bandwidth = 1, grid_size = 3)$components[[1]]$m_hat
#> [1] -2.19290072 -0.01841221 2.09618203