eviews如何做单位根检验,误差修正模型,蒙特卡洛模拟实验

问题描述:

eviews如何做单位根检验,误差修正模型,蒙特卡洛模拟实验
1个回答 分类:综合 2014-11-05

问题解答:

我来补答
先说单位根检验:打开需要检验的序列,在窗口左上角,依次view-unit root test,然后设定检验的参数,确定.
误差修正模型:理论上讲它是VAR模型的特例,在主菜单中quick-estimate var在弹出的对话框中选择vecter error correct设定参数,确定.
蒙特卡罗模拟试验的话,使用交互式操作很难完成,最好使用编程方法,现将我前段时间和朋友交流的一个程序写在下面,它用以模拟线性回归系数的分布:
'Simulation of OLS estimators using MC method

'Objective equation is y=0.3+12*x
'Disturbance N(0,2)
'Repeat 100 times
'(c)2012 by sinxlg1,all rights reserved

 
wfcreate MC_OLSestimators u 100

 scalar rp=1000
 scalar c0=0.3
 scalar b0=12
 scalar dst_var=2
 matrix(rp,2) coef_mtx
 for !k0=1 to rp
  series x_smlt=@runif(20,100)
  series dst=dst_var*@rnorm
  series y_smlt=c0+b0*x_smlt+dst
  equation rg.ls y_smlt=c(1)+c(2)*x_smlt
  coef_mtx(!k0,1)=@coefs(1)
  coef_mtx(!k0,2)=@coefs(2) 
 next
 freeze(coef_grph) coef_mtx.distplot
 freeze(coef_stats) coef_mtx.stats
 show coef_grph
 show coef_stats
 
得到效果如下
 

 
 
 
 
展开全文阅读
剩余:2000
下一页:练习2.3