全部版块 我的主页
论坛 计量经济学与统计论坛 五区 计量经济学与统计软件 EViews专版
3353 1
2005-09-03

the program is used the maximum likehood method the estiamte the parameter,but when i run the program with the data,the result always printed warning such as:"WARNING: Singular covariance - coefficients are not unique ", how can i modify the program to get rid of the warning

'change path to program path %path = @runpath + "../data/" cd %path

' load workfile load gerus

series y = 100*dlog(ger)

' set sample (1/2/82-7/9/92) as in Table 1, column 1 ' 10/6/86 is obs 3945 sample s0 2750 2750 sample s1 2751 5392 smpl s1

' get starting values from Gaussian EGARCH-M equation eq1 eq1.arch(1,1) y c show eq1.output

' declare and initialize parameters coef(1) mu=eq1.c(1) coef(1) omega1=eq1.c(2) coef(1) omega2=eq1.c(3) coef(1) omega3=eq1.c(4) coef(1) a=0.45 coef(1) lambda=4

' set presample values of expressions in logl smpl s0 series sig2=omega1(1) series res=0 series dum=0

' set up GARCH likelihood logl ll1 ll1.append @logl logl ll1.append res=y-mu(1) ll1.append sig2= omega1(1)+omega2(1)*y(-1)^2 +omega3(1)*sig2(-1) ll1.append x=res/@sqrt(sig2)/(@gamma(2/lambda(1))/@sqrt(@gamma(3/lambda(1))*@gamma(1/lambda(1))*(1-3*a(1)+3*a(1)^2)-@gamma(2/lambda(1))^2*(1-2*a(1))^2))+(1-2*a(1)) ll1.append logl0=@log(lambda(1)*@gamma(2/lambda(1))/(@gamma(2/lambda(1))/@sqrt(@gamma(3/lambda(1))*@gamma(1/lambda(1))*(1-3*a(1)+3*a(1)^2)-@gamma(2/lambda(1))^2*(1-2*a(1))^2))/@gamma(1/lambda(1))^2)-(1/a(1))^lambda(1)*((@gamma(2/lambda(1))/@gamma(1/lambda(1)))^lambda(1))*@abs(x)^lambda(1) ll1.append logl1 =@log(lambda(1)*@gamma(2/lambda(1))/(@gamma(2/lambda(1))/@sqrt(@gamma(3/lambda(1))*@gamma(1/lambda(1))*(1-3*a(1)+3*a(1)^2)-@gamma(2/lambda(1))^2*(1-2*a(1))^2))/@gamma(1/lambda(1))^2)-(1-1/a(1))^lambda(1)*((@gamma(2/lambda(1))/@gamma(1/lambda(1)))^lambda(1))*@abs(x)^lambda(1) ll1.append logl = @recode(x<=0,logl0,logl1)

' estimate and display output smpl s1 ll1.ml(showopts, m=1000, c=1e-5)

'estimate same model using EViews' ' build-in function

equation eq2 eq2.arch(1,1,garch) y c show eq2 show ll1.output

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2005-9-10 22:08:00

楼台

虽然我不能回答您的问题,但是我想问您几个我碰到的问题,行么?

我的QQ是:63511000

二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群