Kern.fun | R Documentation |
Kern.fun
computes the n x n matrix of kernels used in the integrated moment class
of estimators.
Kern.fun(Z, Kern = "Euclid", X = NULL, Y = NULL)
Z |
n x p matrix of instrumental variables |
Kern |
type of kernel desired. |
X |
matrix of endogenous covariates. Ought to be demeaned. |
Y |
the outcome variable. Ought to be demeaned. |
The (i,j)
'th elements of available kernel methods are
Negative of the Euclidean distance between two vectors: -||Z_i-Z_j||
The weighted Gaussian kernel: exp(-0.5(Z_i-Z_j)'V^-1(Z_i-Z_j)) where V is the variance of V
The unweighted Gaussian kernel: exp(-||Z_i-Z_j||^2)
The kernel of Dominguez & Lobato 2004: 1/n\sum{l=1}^n I(Z_i\le Z_l)I(Z_j\le Z_l)
The projected version of the DL in Escanciano 2006.
The kernel used in Antoine & Lavergne 2014. See page 60 of paper.
WMD à la Fuller (1977) used in Antoine & Lavergne 2014. See page 64 of paper.
the n\times n
kernel matrix
set.seed(12); X = rnorm(5); Z=cbind(X,abs(X)); Kern.fun(Z,"DL")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.