local_lin | R Documentation |
Estimates E(Y|X) at the observed X by local linear regression. We use a Gaussian kernel, and also output the kernel estimator of the density of X.
local_lin(data, h = 1)
data |
is an environment variable containing the relevant data: - data$Y a matrix of size n x Tmax containing the values of the dependent variable Y. - data$X an array of size n x Tmax x dimX containing the values of the covariates X. |
h |
(default 1) the bandwidth for the local linear regressions. We increase it at points where the regression is degenerate otherwise. |
a list containing. - condlMeans: a vector of length n containing the estimates for P(S = j - 1 | X) at each observation. - densityEstimate: a vector of length n containing, at each row (individual), the estimated density for having covariates X.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.