imlmreg.fit: Generic Linear Integrated Moment Regression

View source: R/dCovReg.R

imlmreg.fitR Documentation

Generic Linear Integrated Moment Regression

Description

imlmreg.fit runs a generic linear integrated moment regression allowing for different kernels.

Usage

imlmreg.fit(Y, X, Z, Kern = "Euclid", vctype = "HC3")

Arguments

Y

outcome variable

X

matrix of covariates.

Z

matrix of instruments

Kern

type of kernel. See Details for available kernels

vctype

type of sandwich covariance matrix (see vcovHC)

Details

The (i,j)'th elements of available kernel methods are

"Euclid"

Euclidean distance between two vectors: ||Z_i-Z_j||

"Gauss.W"

The weighted Gaussian kernel: exp(-0.5(Z_i-Z_j)'V^-1(Z_i-Z_j)) where V is the variance of V

"Gauss"

The unweighted Gaussian kernel: exp(-||Z_i-Z_j||^2)

"DL"

The kernel of Dominguez & Lobato 2004: 1/n\sum{l=1}^n I(Z_i\le Z_l)I(Z_j\le Z_l)

"Esc6"

The projected version of the DL in Escanciano 2006.

"WMD"

The kernel used in Antoine & Lavergne 2014. See page 60 of paper.

"WMDF"

The Fuller (1977)-like modification of the kernel in Antoine & Lavergne 2014. See page 64 of paper.

Value

an IV regression object which also contains coefficients, standard errors, etc.

Examples

## Generate data and run MMD regression
n=200; set.seed(12); X = rnorm(n); er = (rchisq(n,df=1)-1)/sqrt(2); Z=X
X=scale(abs(X))+er/sqrt(2); Y=X+er
summary(imlmreg.fit(Y=Y,X=X,Z=Z))
summary(ivreg::ivreg(formula = Y ~ X | Z)) #compare to conventional IV regression

estsyawo/bayesprdopt documentation built on April 2, 2024, 2:18 p.m.