楼主: helen_80223
11846 50

[程序分享] ox报错 [推广有奖]

11
epoh 发表于 2012-4-25 22:11:16
helen_80223 发表于 2012-4-25 21:52
epoh老师:
     您的意思是需要等一段时间才能出来这个t值吗?非常感谢
恩,约五分钟
                       Regime 1       Regime 2      Regime 3
                                 bb                 bb              bb
Const(Reg.1)   0.305202  
Const(Reg.2)                       0.561997  
Const(Reg.3)                                          0.011184  
bb_1               0.998721   0.998721    0.998721
ss_1               -0.027467  -0.027467   -0.027467   
ff_1              -21.637451 -21.637451  -21.637451
cc_1              47.507210  47.507210   47.507210  
gg_1               0.001605   0.001605    0.001605
ee_1              -0.002364  -0.002364   -0.002364
eee_1            -0.003546  -0.003546   -0.003546
  SE (Reg.1)    3.057883   
  SE (Reg.2)                      1.906766  
  SE (Reg.3)                                         4.651493   

12
zwrin 发表于 2012-4-26 11:50:58
epoh老师好热心啊

13
helen_80223 发表于 2012-4-26 15:50:26
那出现这个呢Warning: run first StdErr().还能出现t值吗?

14
epoh 发表于 2012-4-26 16:21:39
helen_80223 发表于 2012-4-26 15:50
那出现这个呢Warning: run first StdErr().还能出现t值吗?
你是在哪种情况下(执行哪种模型程序)
跑出这个信息

15
helen_80223 发表于 2012-4-26 17:24:53
epoh老师:
     您好!
     那脉冲响应函数该怎么做呢?

16
epoh 发表于 2012-4-26 18:13:43
zwrin 发表于 2012-4-26 11:50
epoh老师好热心啊
请参考8楼,我写的安装说明,很容易就可以运行
   https://bbs.pinggu.org/thread-1197449-1-1.html

17
epoh 发表于 2012-4-26 18:14:24
helen_80223 发表于 2012-4-26 17:24
epoh老师:
     您好!
     那脉冲响应函数该怎么做呢?
Impulse(const h, const fIrCum, const fIrOrth)
msvar->Impulse(20,TRUE,TRUE)

h : a positive integer for the number of periods to trace the response function
fIrCum : compute the cumulated impulse response coefficients
fIrOrtho : compute the orthogonalised impulse response coefficients

18
helen_80223 发表于 2012-4-27 11:57:43
epoh老师:
    您好!
    我将ff和cc都乘了100后对比了各种msvar模型,有些是跑不出来,报错说是到了什么边界,有些是信息准则太大,我选择了大概三种模型一个是MSIH94)var(1),一个是MSIAH(4)VAR(1),还有一个是MSH(4)VAR(1),之后我先跑来了这个程序您看一下,还是没有出来t值和脉冲响应函数图
#include <oxstd.h>
#import  <msvar130>

main()
{
        decl time=timer();
        decl msvar = new MSVAR();
        msvar->IsOxPack(FALSE);
        msvar->LoadIn7("shuju.in7");
        decl p=1;  
    msvar->Select(Y_VAR, {         "bb", 0, p,"gg", 0 ,p, "ss", 0, p, "ff", 0, p,
                                                        "cc",  0, p,"ee", 0, p,"eee",0,p  });
        msvar->SetSample(1, 1, 1568, 1);
        msvar->SetModel(MSIAH,4);

        format(120);
        msvar->Estimate();
       

    msvar->CycleDating();                                // prints regime classification
        msvar->TestAsy();                                        // asymmetry tests
        msvar->DrawResults();                                // shows graphics
        msvar->DrawErrors(TRUE);                        // residuals and analysis
        msvar->DrawFit();                                        // model fit
        msvar->DrawModelAnalysis();                        // model analysis
        msvar->CycleDating();                                // prints regime classification
        msvar->TestAsy();                                        // asymmetry tests
        msvar->Impulse("const",20, "const","fIrCum", "const","fIrOrth");
    msvar->Impulse(20,TRUE,TRUE);

       
        print("\n\n****\ttime passed: ",         timespan(time), "\t****\n");
}

结果报错如下: Warning: run first StdErr().

Runtime error: 'string[6] == int' bad operand
Runtime error occurred in Impulse(566), call trace:
C:\hmk\MSVAR\INCLUDE\MsvarFor.ox (566): Impulse
C:\Program Files\Ox\package\msvar\Text14.ox (28): main

19
epoh 发表于 2012-4-27 15:03:21
helen_80223 发表于 2012-4-27 11:57
epoh老师:
    您好!
    我将ff和cc都乘了100后对比了各种msvar模型,有些是跑不出来,报错说是到了什 ...
msvardoc.pdf  page 25/26
  In general it is not advised to work with a number of regimes
  M >= 4 due to local maxima and parameter inflation.

由于你的模型parameters太多(348),StdErr()似乎没有动作
最好仔细看一下说明,模型不要超出范围.

  MSIAH model type not implemented for impulse-reponse analysis

20
helen_80223 发表于 2012-4-27 17:04:32
epoh老师:
     您好!那报错出现的
Runtime error: 'string[6] == int' bad operand
Runtime error occurred in Impulse(566), call trace:
这两句什么意思?

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

本版微信群
加好友,备注cda
拉您进交流群
GMT+8, 2025-12-26 14:53