版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
1、Applied Econometrics,William Greene Department of Economics Stern School of Business,Applied Econometrics,13. Instrumental Variables,Instrumental Variables,Framework: y = X + , K variables in X. There exists a set of K variables, Z such that plim(ZX/n) 0 but plim(Z/n) = 0 The variables in Z are call
2、ed instrumental variables. An alternative (to least squares) estimator of is bIV = (ZX)-1Zy We consider the following: Why use this estimator? What are its properties compared to least squares? We will also examine an important application,IV Estimators,Consistent bIV = (ZX)-1Zy = (ZX/n)-1 (ZX/n)+ (
3、ZX/n)-1Z/n = + (ZX/n)-1Z/n Asymptotically normal (same approach to proof as for OLS) Inefficient to be shown.,LS as an IV Estimator,The least squares estimator is (X X)-1Xy = (X X)-1ixiyi = + (X X)-1ixii If plim(XX/n) = Q nonzero plim(X/n) = 0 Under the usual assumptions LS is an IV estimator X is i
4、ts own instrument.,IV Estimation,Why use an IV estimator? Suppose that X and are not uncorrelated. Then least squares is neither unbiased nor consistent. Recall the proof of consistency of least squares: b = + (XX/n)-1(X/n). Plim b = requires plim(X/n) = 0. If this does not hold, the estimator is in
5、consistent.,A Popular Misconception,A popular misconception. If only one variable in X is correlated with , the other coefficients are consistently estimated. False. The problem is “smeared” over the other coefficients.,The General Result,By construction, the IV estimator is consistent. So, we have
6、an estimator that is consistent when least squares is not.,Asymptotic Covariance Matrix of bIV,Asymptotic Efficiency,Asymptotic efficiency of the IV estimator. The variance is larger than that of LS. (A large sample type of Gauss-Markov result is at work.) (1) Its a moot point. LS is inconsistent. (
7、2) Mean squared error is uncertain: MSEestimator|=Variance + square of bias. IV may be better or worse. Depends on the data,Two Stage Least Squares,How to use an “excess” of instrumental variables (1) X is K variables. Some (at least one) of the K variables in X are correlated with . (2) Z is M K va
8、riables. Some of the variables in Z are also in X, some are not. None of the variables in Z are correlated with . (3) Which K variables to use to compute ZX and Zy?,Choosing the Instruments,Choose K randomly? Choose the included Xs and the remainder randomly? Use all of them? How? A theorem: (Brundy
9、 and Jorgenson, ca. 1972) There is a most efficient way to construct the IV estimator from this subset: (1) For each column (variable) in X, compute the predictions of that variable using all the columns of Z. (2) Linearly regress y on these K predictions. This is two stage least squares,Algebraic E
10、quivalence,Two stage least squares is equivalent to (1) each variable in X that is also in Z is replaced by itself. (2) Variables in X that are not in Z are replaced by predictions of that X with all the variables in Z that are not in X.,2SLS Algebra,Asymptotic Covariance Matrix for 2SLS,2SLS Has La
11、rger Variance than LS,Estimating 2,Measurement Error,y = x* + all of the usual assumptions x = x* + uthe true x* is not observed (education vs. years of school) What happens when y is regressed on x? Least squares attenutation:,Why Is Least Squares Attenuated?,y = x* + x = x* + u y = x + ( - u) y =
12、x + v, cov(x,v) = - var(u) Some of the variation in x is not associated with variation in y. The effect of variation in x on y is dampened by the measurement error.,Measurement Error in Multiple Regression,Twins,Application from the literature: Ashenfelter/Kreuger: A wage equation that includes “sch
13、ooling.”,Orthodoxy,A proxy is not an instrumental variable Instrument is a noun, not a verb,Applied Econometrics,William Greene Department of Economics Stern School of Business,Applied Econometrics,14. Nonlinear Regression and Nonlinear Least Squares,Nonlinear Regression,What makes a regression mode
14、l “nonlinear?” Nonlinear functional form? Regression model: yi = f( xi , ) + i Not necessarily: yi = exp() + 2*xi + i 1 = exp() yi = exp()xiexp(i) is “loglinear” Models can be nonlinear in the functional form of the relationship between y and x, and not be nonlinear for purposes here. We will redefi
15、ne “nonlinear” shortly, as we proceed.,Nonlinear Least Squares,Least squares: Minimize wrt i yi - f(xi,)2 = i ei2 First order conditions: iyi- f(xi,)2 / = i(-2)yi- f(xi,) f(xi,)/ = -i ei xi0 = 0(familiar?) There is no explicit solution, b = f(data) like LS. (Nonlinearity of the FOC defines nonlinear
16、 model),Example: NIST,How to solve this kind of set of equations: Example, yi = 0 + 1xi2 + i. i ei2/0 = i (-1) (yi - 0 - 1xi2) 1 = 0 i ei2/1 = i (-1) (yi - 0 - 1 xi2) xi2 = 0 i ei2/2 = i (-1) (yi - 0 - 1 xi2) 1 xi2lnxi = 0 Nonlinear equations require a nonlinear solution. Well return to that problem
17、 shortly. This defines a nonlinear regression model. I.e., when the first order conditions are not linear in . (!) Check your understanding. What does this produce if f( xi , ) = xi? (I.e., a linear model),The Linearized Regression Model,Linear Taylor series: y = f(xi,) + . Expand the regression aro
18、und some point, 0. f(xi,) f(xi,0) + kf(xi,0)/k0( k - k0) = f(xi,0) + k xi0 ( k - k0) = f(xi,0) - k xi0k0 + k xi0k = f0 + k xi0k which looks linear. The pseudo-regressors are the derivative functions in the linearized model.,Estimating Asy.Varb,Computing the asymptotic covariance matrix for the nonli
19、near least squares estimator using the pseudo regressors and the sum of squares.,Gauss-Marquardt Algorithm,Given a coefficient vector at step m, find the vector for step m+1 by b(m), b(m+1) = b(m) + X0(m)X0(m)-1X0(m)e0(m) Columns of X0(m) are the derivatives, f(xi,b(m)/b(m) e0 = vector of residuals,
20、 y - fx,b(m) “Update” vector is the slopes in the regression of the residuals on the pseudo-regressors. Update is zero when they are orthogonal. (Just like LS),A NIST Application,Y X 2.138 1.309 3.421 1.471 3.597 1.490 y = 0 + 1x2 + . 4.340 1.565 4.882 1.611 xi0 = 1, x2, 1x2logx 5.660 1.680,Iteratio
21、ns,NLSQ;LHS=Y ;FCN=b0+B1*XB2 ;LABELS=b0,B1,B2 ;MAXIT=500;TLF;TLB;OUTPUT=1;DFC ;START=0,1,5 $ Begin NLSQ iterations. Linearized regression. Iteration= 1; Sum of squares= 149.719219 ; Gradient= 149.718223 Iteration= 2; Sum of squares= 5.04072877 ; Gradient= 5.03960538 Iteration= 3; Sum of squares= .13
22、7768222E-01; Gradient= .125711747E-01 Iteration= 4; Sum of squares= .186786786E-01; Gradient= .174668584E-01 Iteration= 5; Sum of squares= .121182327E-02; Gradient= .301702148E-08 Iteration= 6; Sum of squares= .121182025E-02; Gradient= .134513256E-15 Iteration= 7; Sum of squares= .121182025E-02; Gra
23、dient= .644990175E-20 Convergence achieved,Stata Version 9,Most maximum likelihood estimators now test for convergence using the Hessian-scaled gradient, g*inv(H)*g. This criterion ensures that the gradient is close to zero when scaled by the Hessian (the curvature of the likelihood or pseudolikelih
24、ood surface at the optimum) and provides greater assurance of convergence for models whose likelihoods tend to be difficult to optimize, such as those for arch, asmprobit, and scobit. See R maximize.,Results,+-+ | User Defined Optimization | | Nonlinear least squares regression Weighting variable =
25、none | | Number of iterations completed = 30 | | Dep. var. = Y Mean= 4.006333333 , S.D.= 1.233983576 | | Model size: Observations = 6, Parameters = 3, Deg.Fr.= 3 | | Residuals: Sum of squares= .1211820252D-02, Std.Dev.= .02010 | | Fit: R-squared= .999841, Adjusted R-squared = .99973 | | (Note: Not u
26、sing OLS. R-squared is not bounded in 0,1 | | Model test: F 2, 3 = 9422.64, Prob value = .00000 | | Diagnostic: Log-L = 17.0085, Restricted(b=0) Log-L = -9.2282 | | LogAmemiyaPrCrt.= -7.409, Akaike Info. Crt.= -4.670 | +-+ +-+-+-+-+-+-+ |Variable | Coefficient | Standard Error |b/St.Er.|P|Z|z | Mean
27、 of X| +-+-+-+-+-+-+ B0 -.5455928058 .22460069 -2.429 .0151 B1 1.080717551 .13697694 7.890 .0000 B2 3.372865575 .17846759 18.899 .0000,NLS Solution,The pseudo regressors and residuals at the solution are: 1 x2 1x2 lnx e0 12.479830.721624 .0036 13.675661.5331 -.0058 13.838261.65415-.0055 14.529722.19
28、255-.0097 14.994662.57397 .0298 15.753583.22585-.0124 X0e0 = .3375078D-13 .3167466D-12 .1283528D-10,Application: Doctor Visits,German Individual Health Care data: N=27,236 Model for number of visits to the doctor,Conditional Mean and Projection,Notice the problem with the linear approach. Negative p
29、redictions.,Most of the data are in here,This area is outside the range of the data,Nonlinear Model Specification,Nonlinear Regression Model y=exp(x) + X =one,age,health_status, married, education, household_income, nkids,NLS Iterations,- nlsq;lhs=docvis;start=0,0,0,0,0,0,0;labels=k_b;fcn=exp(b1x);m
30、axit=25;out. Begin NLSQ iterations. Linearized regression. Iteration= 1; Sum of squares= 1014865.00 ; Gradient= 257025.070 Iteration= 2; Sum of squares= .130154610E+11; Gradient= .130145942E+11 Iteration= 3; Sum of squares= .175441482E+10; Gradient= .175354986E+10 Iteration= 4; Sum of squares= 23536
31、9144. ; Gradient= 234509185. Iteration= 5; Sum of squares= 31610466.6 ; Gradient= 30763872.3 Iteration= 6; Sum of squares= 4684627.59 ; Gradient= 3871393.70 Iteration= 7; Sum of squares= 1224759.31 ; Gradient= 467169.410 Iteration= 8; Sum of squares= 778596.192 ; Gradient= 33500.2809 Iteration= 9; S
32、um of squares= 746343.830 ; Gradient= 450.321350 Iteration= 10; Sum of squares= 745898.272 ; Gradient= .287180441 Iteration= 11; Sum of squares= 745897.985 ; Gradient= .929823308E-03 Iteration= 12; Sum of squares= 745897.984 ; Gradient= .839914514E-05 Iteration= 13; Sum of squares= 745897.984 ; Grad
33、ient= .991471058E-07 Iteration= 14; Sum of squares= 745897.984 ; Gradient= .132954206E-08 Iteration= 15; Sum of squares= 745897.984 ; Gradient= .188041512E-10,Nonlinear Regression Results,+-+ | Nonlinear least squares regression | | LHS=DOCVIS Mean = 3.183525 | | Standard deviation = 5.689690 | | WT
34、S=none Number of observs. = 27326 | | Model size Parameters = 7 | | Degrees of freedom = 27319 | | Residuals Sum of squares = 745898.0 | | Standard error of e = 5.224584 | | Fit R-squared = .1567778 | | Adjusted R-squared = .1568087 | | Info criter. LogAmemiya Prd. Crt. = 3.307006 | | Akaike Info. C
35、riter. = 3.307263 | | Not using OLS or no constant. Rsqd k=col(x)$ nlsq;lhs=docvis;start=0,0,0,0,0,0,0 ;labels=k_b;fcn=exp(b1x); matr;xbar=mean(x)$ calc;mean=exp(xbarb)$ matr;me=b*mean$ matr;g=mean*iden(k)+mean*b*xbar$ matr;vme=g*varb*g$ matr;stat(me,vme)$,Partial Effects at the Means of X,+-+ |Number of observations in current sample = 27326 | |Number of parameters computed here = 7 | |Number of degrees of freedom
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2026年海油集团项目管理工程师项目问题解决方法含答案
- 2025年院感知识考试卷附答案
- 汽车交通团队奋进轨迹
- 2026年甘肃省酒泉肃州区飞天路社区现面向社会招聘公益性岗位人员考试参考题库及答案解析
- 2025四川长江担保集团有限公司及其子公司第六批员工招聘10人笔试模拟试题及答案解析
- 2026山东菏泽市国资委招聘市属企业工作人员第二次考察递补笔试备考试题及答案解析
- 2025山东日照市新岚山人力资源有限公司招聘1人笔试备考试题及答案解析
- 2026年芜湖市弋江区招聘警民联调室专职人民调解员10人笔试备考题库及答案解析
- 2026年聊城文苑中学教师招聘考试备考试题及答案解析
- 2026湖南长沙市浏阳市招聘卫健系统专业人才(第二批)10人笔试备考题库及答案解析
- 血液透析护理文件书写规范
- 雅培化学发光销售培训
- 2025年四年级语文知识点总结(全册高频考点)
- 2025年及未来5年市场数据中国工业液压过滤器市场竞争态势及投资战略规划研究报告
- 2025年教学研究员岗位招聘面试参考题库及参考答案
- 2025年福建省领导干部任职前廉政法规知识测试题库及答案
- 2025年清远市公安局分局警务辅助人员招聘考试试题(附答案)
- 2025年煤矿煤矿维修设备操作与维护人员专业安全培训试卷及答案
- 某某县高级中学教学综合楼及学生食堂建设工程可行性研究报告
- 中国环丙胺行业市场前景预测及投资价值评估分析报告
- 重庆市建筑工程施工图设计文件编制技术规定(2024年版)
评论
0/150
提交评论