Keywords - Function groups - @ A B C D E F G H I J K L M N O P Q R S T U V W X Y Z

Library: eiv
See also: eivlinearinstrvec

Quantlet: eivlinearinstr
Description: eivlinearinstr presents the moment estimates of the regression coefficients in the measurement error model with single predictor, which has an instrumental variable W. All of the variables obey normal distributions. All parameters are estimated by moment method in measurement error models.

Reference(s):

Link:
Usage: {beta1,beta0,varbeta1,varbeta0} = eivlinearinstr(x,w,y)
Input:
x n x 1 matrix, the design variables
w n x 1 matrix, the instrumental variables
y n x 1 matrix, the response
Output:
beta1 scalar, the estimate
beta0 scalar, the estimate
varbeta1 scalar, the estimate of the variance of the estimate of beta1
varbeta0 scalar, the estimate of the variance of the estimate of beta0

Example:
library("eiv")
n=100
randomize(n)
V=uniform(n,3).*#(4,3,4)'+#(3,3,3)'
y=V[,1]
x=V[,2]
w=V[,3]
gest=eivlinearinstr(x,w,y)
gest.beta1
gest.beta0
gest.varbeta1
gest.varbeta0

Result:
Contents of beta1
[1,]  -1.1709
Contents of beta0
[1,]   10.135
Contents of varbeta1
[1,]   7.3944
Contents of varbeta0
[1,]   152.02



Author: H. Liang, W. Haerdle, 19970730 license MD*Tech
(C) MD*TECH Method and Data Technologies, 05.02.2006