[Gretl-users] Implement new criterion for var lag selection

Gian Lorenzo Spisso glspisso at gmail.com
Tue Jul 9 11:08:26 EDT 2013


Thank you, Riccardo! The script is working, I am only puzzled by one thing:
in the second half the standard procedure is run once more and the HJC
column is added. But between the first and the second run the result
changes dramatically between the first three criterions. You can see the
result and the aforementioned inconsistency in the attachment.

@Allin I noticed and I just assumed it was implicitly referring to known
results with simulations on the other criterions(he quotes Lutkepol 1985
but my subscription doesn't allow me to read it),
http://onlinelibrary.wiley.com/doi/10.1111/j.1467-9892.1985.tb00396.x/abstract.
It definetly warrants deeper investigation. It would be interesting to
rerun his montecarlo simulations and see how different criteria compares.

Again thanks for your prompt responses.


On Tue, Jul 9, 2013 at 4:20 PM, Riccardo (Jack) Lucchetti <
r.lucchetti at univpm.it> wrote:

> On Tue, 9 Jul 2013, Gian Lorenzo Spisso wrote:
>
>  Dear Riccardo,
>> I attach a screenshot of the relevant part.
>> You can see the formulas for the two criterion, and the new criterion
>> proposed by Hatemi which simply averages the two. He then goes on and uses
>> a Montecarlo simulation to show that this mixed criterion as higher
>> probability in picking the right lag.
>>
>
> I suppose this is close to what you want: first we run the native gretl
> command, then the customised version including the HJC.
>
> <hansl>
> set echo off
> set messages off
>
> open denmark
> list X = 1 2 3 4
> maxlag = 8
>
> var maxlag X --lagselect
>
> crit = zeros(maxlag, 5)
> colnames(crit,"lag AIC BIC HQC HJC")
>
> smpl +maxlag ;
> loop i=1..maxlag --quiet
>     var i X --silent
>     crit[i,] = i ~ $aic ~ $bic ~ $hqc ~ 0.5*($bic + $hqc)
> end loop
> best = iminc(crit[,2:5])
> colnames(best,"bAIC bBIC bHQC bHJC")
>
> smpl full
> print crit best
> </hansl>
>
>
> ------------------------------**-------------------------
>   Riccardo (Jack) Lucchetti
>   Dipartimento di Scienze Economiche e Sociali (DiSES)
>
>   Università Politecnica delle Marche
>   (formerly known as Università di Ancona)
>
>   r.lucchetti at univpm.it
>   http://www2.econ.univpm.it/**servizi/hpp/lucchetti<http://www2.econ.univpm.it/servizi/hpp/lucchetti>
> ------------------------------**-------------------------
>



-- 
Gian Lorenzo Spisso


*Phone*: 415-359-4330
*Skype*: glspisso
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.wfu.edu/pipermail/gretl-users/attachments/20130709/4f5eff30/attachment.html 
-------------- next part --------------
gretl version 1.9.12
Current session: 2013-07-09 16:47
? set echo off

periodicity: 4, maxobs: 68
observations range: 1991:1 to 2007:4

Listing 10 variables:
  0) const        1) i            2) r            3) infl       
  4) out_gap      5) d_i          6) d_r          7) d_infl     
  8) d_out_gap    9) uhat1      

VAR system, maximum lag order 8

The asterisks below indicate the best (that is, minimized) values
of the respective information criteria, AIC = Akaike criterion,
BIC = Schwarz Bayesian criterion and HQC = Hannan-Quinn criterion.

lags        loglik    p(LR)       AIC          BIC          HQC

   1    -244.25073             8.957652     9.661902     9.232563 
   2    -207.78015  0.00000    8.263734     9.531384*    8.758573 
   3    -180.12610  0.00000    7.868681     9.699731     8.583449 
   4    -149.16754  0.00000    7.361612     9.756062     8.296308*
   5    -128.92686  0.00066    7.217860    10.175710     8.372485 
   6    -112.67072  0.00857    7.209177    10.730427     8.583730 
   7    -100.25632  0.07290    7.330723    11.415373     8.925205 
   8     -72.25874  0.00000    6.924025*   11.572075     8.738436 
crit (8 x 5)

         lag          AIC          BIC          HQC          HJC 
      1.0000       10.113       10.812       10.387       10.599 
      2.0000       9.9597       11.216       10.451       10.834 
      3.0000       9.9822       11.797       10.692       11.245 
      4.0000       9.4481       11.822       10.377       11.099 
      5.0000       9.3979       12.330       10.545       11.437 
      6.0000       9.3671       12.858       10.732       11.795 
      7.0000       9.5299       13.579       11.114       12.346 
      8.0000       6.9240       11.572       8.7384       10.155 

best (1 x 4)

        bAIC         bBIC         bHQC         bHJC 
           8            1            8            8 


More information about the Gretl-users mailing list