I want to estimate an equation with an AR(1) term and save the coefficients. I can specify an equation as follows:
equation equ1.ls x1 c y1 y2 ar(1)
but this does not save the coefficients. The usual way of saving coefficients is to specify an equation like so:
equation equ1.ls x1=c(1)+c2)*y1+c(3)*y2
where the coefficients are saved as c(1), c(2) etc. You cannot, however specify an ar(1) term using this method. Do you know how I can include an AR(1) term and save the coefficients?
Saving coefficients with an AR(1) term
Moderators: EViews Gareth, EViews Moderator
-
EViews Gareth
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13583
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Saving coefficients with an AR(1) term
Not quite sure what you mean by "save the coefficients", but the coefficient estimates are stored in the C vector, whether you specify an equation by list or by expression. Thus if you write your equation as:
equation equ1.ls x1 c y1 y2 ar(1)
the ar term will be in c(4).
If you want to include an AR term in an equation by expression, you can in the following way:
equation equ1.ls x1=c(1)+c(2)*y1+c(3)*y4+[ar(1)=c(4)]
Further, whether you specify your equation by list or by expression, you can access the coefficients by using the @coef data member:
scalar arterm = equ1.@coef(4)
equation equ1.ls x1 c y1 y2 ar(1)
the ar term will be in c(4).
If you want to include an AR term in an equation by expression, you can in the following way:
equation equ1.ls x1=c(1)+c(2)*y1+c(3)*y4+[ar(1)=c(4)]
Further, whether you specify your equation by list or by expression, you can access the coefficients by using the @coef data member:
scalar arterm = equ1.@coef(4)
Who is online
Users browsing this forum: No registered users and 1 guest
