楼主: yexingtianma
2702 3

swarch模型hanmilton1994论文的程序 [推广有奖]

  • 5关注
  • 2粉丝

已卖:87份资源

教授

84%

还不是VIP/贵宾

-

威望
0
论坛币
37310 个
通用积分
10.2218
学术水平
8 点
热心指数
8 点
信用等级
6 点
经验
19405 点
帖子
277
精华
0
在线时间
2882 小时
注册时间
2007-10-8
最后登录
2025-12-26

楼主
yexingtianma 发表于 2010-8-7 17:33:39 |AI写论文
150论坛币
hanmilton1994论文的程序,改变swarch模型的状态个个数,如将3状态改变为2状态,ns=3变为ns=2,为什么程序的运行出现问题?将3状态改变为2状态,ns=3变为ns=2时候已经将初始值改为 let th[11,1] =
           0.34775  0.25589  0.55992  0.06036  0.16047  0.051751
           0.99195  0.99907  5.7857  0.44348  3.7547 ;
出错信息显示为:Stack trace:
   matpm called from C:\gauss\ARCH\Maxseek, line 190
   echoo called from C:gauss\ARCH\Maxseek, line 227
请问如何解决,QQ396569605可详细告知。

最佳答案

fftangwen 查看完整内容

还需要改个地方,你把ipm=3,改成ipm=1。 ipm是估计概率转移矩阵的参数,=3是用作者自己编写的那一套代码去估计,后面程序里有说明; =1是直接估计2*2矩阵中的p11和p22 另外,我用的是gauss7.0,改了之后运行无误 FINAL ESTIMATES Value of log likelihood: -2845.4269 Coefficients: 0.33000284 0.26802494 23.460591 0.11939691 0.25590515 0.00015927405 1 ...
关键词:hanmilton SWARCH模型 Milton SWARCH ARCH模型 SWARCH gauss程序 hanmilton1994

沙发
fftangwen 发表于 2010-8-7 17:33:40
还需要改个地方,你把ipm=3,改成ipm=1。
ipm是估计概率转移矩阵的参数,=3是用作者自己编写的那一套代码去估计,后面程序里有说明;
=1是直接估计2*2矩阵中的p11和p22
另外,我用的是gauss7.0,改了之后运行无误
         FINAL ESTIMATES

Value of log likelihood:      -2845.4269

Coefficients:
      0.33000284       0.26802494        23.460591       0.11939691       0.25590515    0.00015927405        10.503320       0.10594459       0.44324573        3.3957401        3.7547000

Constant term in regression      0.33000284
Autoregressive coefficients in regression      0.26802494
Initial variance not neeeded
Constant term in ARCH process       23.460591
Coefficients on lagged epsilon squared in ARCH process      0.11939691       0.25590515
(Transposed) matrix of transition probabilities
  2.5368221e-008     0.0089831327
      0.99999997       0.99101687

The state with no adjustment to ARCH process is state 1, with transition
probability   2.5368221e-008
Vector of variance factors for states 2 through       2.0000000       0.10594459
Coefficient on negative lagged change for asymmetric effect      0.44324573
degree of freedom for t distribution is       5.3957401

Gradient vector:
  6.9179806e-005     0.0011302750  -7.8088182e-005    -0.0020425821    -0.0018203135    0.00015770401  -7.8054892e-005     -0.014099421   -0.00073166419   -0.00026004046       0.00000000
Hessian not positive definite; eigenvalues are
      0.00000000    0.00017917889      0.024908049        1.1920800        70.196701        256.68116        352.48718        424.74669        1439.5269        1983.4422        17026.812
eigenvector associated with smallest eigenvalue is
      0.00000000       0.00000000       0.00000000       0.00000000       0.00000000       0.00000000       0.00000000       0.00000000       0.00000000       0.00000000       0.00000000        1.0000000

Matrix of Markov transition probabilities:

  2.5368221e-008     0.0089831327
      0.99999997       0.99101687

Ergodic probs for full state vector:
      0.00000000   2.2585755e-010   7.9978217e-005     0.0088231762   2.2585744e-010     0.0089031542     0.0088231762       0.97337051

Ergodic probs for primitive states:
    0.0089031547       0.99109685

Log likelihood:
      -2845.4269
已有 1 人评分论坛币 热心指数 收起 理由
zhaomn200145 + 20 + 1 根据规定进行奖励

总评分: 论坛币 + 20  热心指数 + 1   查看全部评分

藤椅
yexingtianma 发表于 2010-8-7 21:42:09
等待高手!

板凳
zhangxi1987 发表于 2010-8-31 09:09:27
增加样本容量怎么更改代码呢

您需要登录后才可以回帖 登录 | 我要注册

本版微信群
加好友,备注jltj
拉您入交流群
GMT+8, 2025-12-29 02:58