Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Heteroskedasticity problem

    hello everyone,

    I am conducting a VAR model for economic growth and globalization. Data is from 1980 to 2022. I have the AGR (annual growth rate of GDP in %) and KOF index (which was retrieved by Dreher 2006). KOF index (1-100 scale) was not stationary so i transformed the KOF into globalization=KOFt/KOFt-1 and solved the stationary issue. I have performed all the steps including: the selection of lags, the model stability, the autocorrelation issue, but now I am having troubles with heteroskedasticity of the residuals. I cannot perform the test in STATA (estat hettest) which says to me last estimates not found (error r301). My ultimate goal is to create Impulse response functions for my two variables AGR and globalization here below is my code
    Code:
    * Example generated by -dataex-. To install: ssc install dataex
    clear
    input int year float(AGR KOF globalization residuals)
    1980      . 23.378174         .           .
    1981      . 23.211115  .9928541           .
    1982      . 22.783043  .9815574           .
    1983      .  23.00968 1.0099477           .
    1984  -1.25 22.789507  .9904312           .
    1985   1.78 23.374466 1.0256679           .
    1986   5.64  22.59832  .9667952   2.0702236
    1987   -.79  23.07755 1.0212063  -4.6659617
    1988  -1.42 24.654205 1.0683199   -1.821009
    1989   9.84 24.972147 1.0128961    7.706656
    1990  -9.58 24.640667   .986726    -16.7239
    1991    -28    28.569 1.1594249   -22.26849
    1992  -7.19  39.75262   1.39146      .34917
    1993   9.56  40.83884 1.0273244 -.035226285
    1994    8.3 32.801414  .8031916    1.012783
    1995  13.32  31.96126  .9743866   11.984923
    1996    9.1  30.01909  .9392337   2.1367476
    1997 -10.92  28.93174  .9637781    -13.2087
    1998   8.83 32.354862 1.1183171   14.909916
    1999  12.89 36.109394 1.1160423   2.0066772
    2000   6.95  39.19376 1.0854174    .3804192
    2001   8.29  42.17943  1.076177    6.129879
    2002   4.54   46.7698 1.1088296  -.01984159
    2003   5.53   47.2565 1.0104063    2.845588
    2004   5.51  47.91206 1.0138725    2.415801
    2005   5.53  48.43103 1.0108316    2.234954
    2006    5.9   50.5421 1.0435892     2.63613
    2007   5.98  53.14189 1.0514382     2.19221
    2008    7.5  56.46306 1.0624963     3.84975
    2009   3.35  58.03797 1.0278927  -1.1103575
    2010   3.71  62.98748 1.0852805   2.1493583
    2011   2.55  61.31259  .9734091  -1.1066909
    2012   1.42  60.45172  .9859594  -.15974425
    2013      1  60.04907  .9933392   -.9909918
    2014   1.77 65.107254 1.0842342    -.348368
    2015   2.22  65.10788 1.0000097  -1.2856524
    2016   3.31 66.630615 1.0233879   1.0711466
    2017    3.8  68.52433  1.028421    .5187215
    2018   4.07  68.01423  .9925559    .9109921
    2019   2.21  68.49394 1.0070531   -.5588056
    2020  -3.13  63.79173  .9313484   -5.208308
    2021   8.63         .         .    9.517865
    2022      3         .         .           .
    end
    I actually don't understand what I am doing wrong? Do you see any problem with my data? what can I do?

    Looking forward your replies,
    thanks in advance

  • #2
    any suggestion please...

    Comment


    • #3
      You haven’t shown the Stata command you typed and the output given — as requested in the FAQ. It’s difficult to make suggestions without that.

      Comment


      • #4
        hello again,
        I am using STATA14. I run a VAR model: var AGR and globalization,lags(3). predict residuals,residual. Now when checking for heteroskedasticity in the residuals, I run the code hettest which provides me with an error (last estimates not found
        r(301);

        Comment


        • #5
          not sure where you are getting the -hettest- command (current and recent versions of Stata would use -estat hettest- but, as the original author, hettest was not designed to work after the -var- command

          Comment


          • #6
            There's no reason to test for heteroskedasticity unless you want to model the variance. Simply use vce(robust) in the -var- command. Then your inference is robust to any kind of heteroskedasticity.

            Comment

            Working...
            X