Parameter Estimation

For technical questions regarding estimation of single equations, systems, VARs, Factor analysis and State Space Models in EViews. General econometric questions and advice should go in the Econometric Discussions forum.

Moderators: EViews Gareth, EViews Moderator

papu
Posts: 1
Joined: Wed Apr 29, 2009 8:47 pm

Parameter Estimation

Postby papu » Wed Apr 29, 2009 11:04 pm

How to estimate the parameters in Eviews with restrictions on the parameters across the equations. The restrictions are of the form a1/b1=a2/b2 for a system consisting of 2 equations of the form:

y=a1*x1+a2*x2+k1 and z=b1*x1+b2*x2+k2

We know what the series y, z, x1, and x2 are.

Thanks

trubador
Did you use forum search?
Posts: 1518
Joined: Thu Nov 20, 2008 12:04 pm

Re: Parameter Estimation

Postby trubador » Thu Apr 30, 2009 1:23 am

Code: Select all

'define the coefficent vectors and the fixed ratio (a1/b1=a2/b2=r)
coef(2) a
coef(2) b
coef(1) r

'first estimate one of the equations via least squares and save the coefficents
equation olsy.ls y = a(1)*x1 + a(2)*x2
!a1=olsy.@coefs(1)
!a2=olsy.@coefs(2)

'estimate remaining equation with respect to previously saved coefficents to find r value
equation olsz.ls z = r(1)*!a1*x1 + r(1)*!a2*x2

'if E(z) = r*E(y), then you can also estimate r ratio via equation olsr.ls z = r(1)*y

'the paramaters we have just estimated are not exact but close to their real values
'therefore we should jointly estimate the paramaters for actual results.

logl joint
joint.append @logl ols
joint.append res1 = y - a(1)*x1 - a(2)*x2
joint.append res2 = z - r(1)*a(1)*x1 - r(1)*a(2)*x2
joint.append ols =-(res1^2 + res2^2)

'estimation will use our previous ols estimations as starting values
joint.ml(showopts, m=1000, c=1e-7)
show joint.output

'you can now easily calculate b coefficients
b(1) = r(1)*a(1)
b(2) = r(1)*a(2)

'you should also try beginning with other equation first and repeat the steps above for b coefficents.
'The results should be nearly identical.

startz
Non-normality and collinearity are NOT problems!
Posts: 3775
Joined: Wed Sep 17, 2008 2:25 pm

Re: Parameter Estimation

Postby startz » Thu Apr 30, 2009 4:57 am

papu wrote:How to estimate the parameters in Eviews with restrictions on the parameters across the equations. The restrictions are of the form a1/b1=a2/b2 for a system consisting of 2 equations of the form:

y=a1*x1+a2*x2+k1 and z=b1*x1+b2*x2+k2

We know what the series y, z, x1, and x2 are.

Thanks

Use a System with the equations
y=a1*x1+a2*x2+k1
z=b1*x1+(a2*b1/a1)*x2+k2

trubador
Did you use forum search?
Posts: 1518
Joined: Thu Nov 20, 2008 12:04 pm

Re: Parameter Estimation

Postby trubador » Thu Apr 30, 2009 1:39 pm

Startz' answer is definitely more clean and spare compared to my unnecessarily circuitous solution. It is indeed the most usual way of doing such an estimation I might add. Since the model now becomes nonlinear in its coefficients, it would be wise to preset the value of a1 coefficient to 1 in order to avoid missing value problem for the sake of estimation process.


Return to “Estimation”

Who is online

Users browsing this forum: No registered users and 17 guests