Hi,
I'm trying to estimate a model of the form equation myEquation.arch(0,2,ged,z,backcast=0.7) varDep myDummies ar(1) ar(2) sar(3) sar(4) ma(12) ar(12) sar(12)
Question 1 : I read that the minimum value of p (.arch(p,q,options)) should be 1. Does that mean the EViews will replace the 0 by 1?
Question 2 : Feeding initial values do not seem to change the end results. Does that mean that EViews computes its own initial values?
Thanks!
Danny
Questions related to arch model
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13600
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Questions related to arch model
1) I think that is a typo - we appear to allow p=0 just fine.
2) By default, yes.
2) By default, yes.
Re: Questions related to arch model
Hi Gareth,
Many thanks again for your help.
Danny
Many thanks again for your help.
Danny
-
KRITIKA MATHUR
- Posts: 1
- Joined: Mon May 30, 2016 4:17 am
Re: Questions related to arch model
There are way too many iterations to run, Do you know how to edit command line in eviews programme so that I can include an independent variable in the variance equation of GARCH?
1. I need to estimate various ARMA GARCH models
2. I have found a program for running ARMA GARCH with an independent variable in the mean equation (find below - program) along with AR, MA terms in mean
3. Can u check what should be the change in the program so that I can include a variable in the variance equation (i need AR, MA terms in mean equation)
I got program from http://forums.eviews.com/viewtopic.php?f=15&t=1175
I made certain changes, I also saw ftp://economia.unica.it/mattana/Econome ... %20Ref.pdf
Program:
%eqname = "EQ01" 'name of equation object that will be used.
%maxAR = "5" 'maximum number of AR terms
%maxMA = "5" 'maximum number of MA terms
%dep = "R0304" 'dependent variable
%regs = "C W0304 " 'independent variables
%criterion = "@AIC" 'which criterion to use enter "@AIC" for Akaike, "@schwarz" for Schwarz, and @HQ for Hannan-Quinn
!maxAR = @val(%maxAR)
!maxMA = @val(%maxMA)
close {%eqname}
'create table for storing critical values.
%matname = "crits"
if @isobject(%matname) then
%matname = "__crits"
if @isobject(%matname) then
delete {%matname}
endif
endif
table(!maxar+2,!maxma+2) {%matname}
{%matname}(1,1) = "AR / MA"
{%matname}.setlines(1) +b
{%matname}.setlines(a) +r
'set sample
smpl @first+!maxAR @last
!mincrit = 1e12 'set the minimum to an artificially large value to begin
'estimate the models
%arstring = ""
for !i=0 to !maxar
'build up string for AR terms.
if !i>0 then
%arstring = %arstring + " ar(" + @str(!i) + ")"
endif
%mastring = ""
for !j=0 to !maxma
'build up string for MA terms
if !j>0 then
%mastring = %mastring + " ma(" + @str(!j) + ")"
endif
'estimate equation
equation {%eqname}.arch {%dep} {%regs} {%arstring} {%mastring}
'capture criterion
if @upper(%criterion) = "@AIC" then
!crit = {%eqname}.@aic
endif
if @upper(%criterion) = "@SCHWARZ" then
!crit = {%eqname}.@schwarz
endif
if @upper(%criterion) = "@HQ" then
!crit = {%eqname}.@hq
endif
'compare criterion
if !crit < !mincrit then
!mincrit = !crit
!bestAR = !i
!bestMA = !j
%bestARstr = %arstring 'store the best ar string
%bestMAstr = %mastring 'store the best ma string
{%matname}.settextcolor(@all) black 'table formatting.
!ii=!i+2
!jj=!j+2
{%matname}.settextcolor(!ii,!jj) red
endif
{%matname}(!i+2,!j+2) = !crit
{%matname}(!i+2,1) = !i
{%matname}(1,!j+2) = !j
next
next
equation {%eqname}.arch {%dep} {%regs} {%bestARstr} {%bestMAstr}
show {%eqname}
show {%matname}
1. I need to estimate various ARMA GARCH models
2. I have found a program for running ARMA GARCH with an independent variable in the mean equation (find below - program) along with AR, MA terms in mean
3. Can u check what should be the change in the program so that I can include a variable in the variance equation (i need AR, MA terms in mean equation)
I got program from http://forums.eviews.com/viewtopic.php?f=15&t=1175
I made certain changes, I also saw ftp://economia.unica.it/mattana/Econome ... %20Ref.pdf
Program:
%eqname = "EQ01" 'name of equation object that will be used.
%maxAR = "5" 'maximum number of AR terms
%maxMA = "5" 'maximum number of MA terms
%dep = "R0304" 'dependent variable
%regs = "C W0304 " 'independent variables
%criterion = "@AIC" 'which criterion to use enter "@AIC" for Akaike, "@schwarz" for Schwarz, and @HQ for Hannan-Quinn
!maxAR = @val(%maxAR)
!maxMA = @val(%maxMA)
close {%eqname}
'create table for storing critical values.
%matname = "crits"
if @isobject(%matname) then
%matname = "__crits"
if @isobject(%matname) then
delete {%matname}
endif
endif
table(!maxar+2,!maxma+2) {%matname}
{%matname}(1,1) = "AR / MA"
{%matname}.setlines(1) +b
{%matname}.setlines(a) +r
'set sample
smpl @first+!maxAR @last
!mincrit = 1e12 'set the minimum to an artificially large value to begin
'estimate the models
%arstring = ""
for !i=0 to !maxar
'build up string for AR terms.
if !i>0 then
%arstring = %arstring + " ar(" + @str(!i) + ")"
endif
%mastring = ""
for !j=0 to !maxma
'build up string for MA terms
if !j>0 then
%mastring = %mastring + " ma(" + @str(!j) + ")"
endif
'estimate equation
equation {%eqname}.arch {%dep} {%regs} {%arstring} {%mastring}
'capture criterion
if @upper(%criterion) = "@AIC" then
!crit = {%eqname}.@aic
endif
if @upper(%criterion) = "@SCHWARZ" then
!crit = {%eqname}.@schwarz
endif
if @upper(%criterion) = "@HQ" then
!crit = {%eqname}.@hq
endif
'compare criterion
if !crit < !mincrit then
!mincrit = !crit
!bestAR = !i
!bestMA = !j
%bestARstr = %arstring 'store the best ar string
%bestMAstr = %mastring 'store the best ma string
{%matname}.settextcolor(@all) black 'table formatting.
!ii=!i+2
!jj=!j+2
{%matname}.settextcolor(!ii,!jj) red
endif
{%matname}(!i+2,!j+2) = !crit
{%matname}(!i+2,1) = !i
{%matname}(1,!j+2) = !j
next
next
equation {%eqname}.arch {%dep} {%regs} {%bestARstr} {%bestMAstr}
show {%eqname}
show {%matname}
Who is online
Users browsing this forum: No registered users and 2 guests
