Equations in a Model

For technical support, tips and tricks, suggestions, or any other information regarding the EViews model object.

Moderators: EViews Gareth, EViews Moderator

KatellL
Posts: 6
Joined: Fri Feb 04, 2011 7:54 am

Equations in a Model

Postby KatellL » Fri Feb 04, 2011 9:29 am

Is there a way to estimate multiple equations in a model simultaneously?

Also, is there a way to print out or look at all of the data from all of the equations in a solved model simultaneously?

Lastly, is there a way to copy and paste mulitple equations from a text editior into a model and have it remain different equations?

I'm going to forecasting many models with multiple equations, and I'm just trying to find the most efficient way to get the equations into the model and to look at the resulting data for analysis.

Thank you in advance for any help or suggestions!

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 12291
Joined: Tue Sep 16, 2008 5:38 pm

Re: Equations in a Model

Postby EViews Gareth » Fri Feb 04, 2011 9:40 am

An equation is only entered into a model once it has been estimated already. There is no quick way to re-estimate all of the equations contained in a model (although you might want to take a look at the EqRefresh Add-in.

From within the model you can click on Proc->Make Group, which will let you view all the variables contained in the model, and lets you specify whether to actuals or solutions etc...

I'm not 100% certain I understand the last question, but can't you just paste directly into the text view of the model?
Follow us on Twitter @IHSEViews

KatellL
Posts: 6
Joined: Fri Feb 04, 2011 7:54 am

Re: Equations in a Model

Postby KatellL » Fri Feb 04, 2011 12:15 pm

Thank you so much for replying so quickly. My first two questions are now resolved.

I have around 100 equations that I have in a text file. Is there anyway to copy them them as a whole and paste them somewhere in EViews where EViews will know that each line is a different equation? Or, is there a symbol, like a semi-colon, that I can put at the end of each equation to signify the end of one equation and the beginning of another?

I'm just trying to not have to either type or copy and paste each equation into the model.

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 12291
Joined: Tue Sep 16, 2008 5:38 pm

Re: Equations in a Model

Postby EViews Gareth » Fri Feb 04, 2011 12:42 pm

As long as there is a carriage return between each equation, the model should recognise them ok.
Follow us on Twitter @IHSEViews

KatellL
Posts: 6
Joined: Fri Feb 04, 2011 7:54 am

Re: Equations in a Model

Postby KatellL » Mon Jul 02, 2012 8:27 am

I'm now wondering if there is a way to have the equation information (see below) for multiple equations in one page. Once again, I have 100 equations, but I've been breaking them up into 4 groups of 25 and I would like to be able to look at all the equation information for all of them at once.

Dependent Variable: LOG(EMP_001)
Method: Least Squares
Date: 06/27/12 Time: 15:36
Sample (adjusted): 1990Q2 2011Q4
Included observations: 87 after adjustments

Variable Coefficient Std. Error t-Statistic Prob.

C 0.883494 0.202550 4.361859 0.0000
LOG(NFSAQ) 0.254758 0.038885 6.551511 0.0000
LOG(NFMFGSAQ) 0.084763 0.011935 7.102177 0.0000
LOG(EMP_001(-1)) 0.678789 0.048193 14.08481 0.0000

R-squared 0.979595 Mean dependent var 10.97733
Adjusted R-squared 0.978858 S.D. dependent var 0.053155
S.E. of regression 0.007729 Akaike info criterion -6.842829
Sum squared resid 0.004958 Schwarz criterion -6.729454
Log likelihood 301.6631 Hannan-Quinn criter. -6.797177
F-statistic 1328.238 Durbin-Watson stat 1.305341
Prob(F-statistic) 0.000000




Thank you!

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 12291
Joined: Tue Sep 16, 2008 5:38 pm

Re: Equations in a Model

Postby EViews Gareth » Mon Jul 02, 2012 8:54 am

I'm going to assume that this isn't model related - you have 100 equations in your workfile, each have been estimated, and you want to see summary information about them in one go?

You can either put them in a spool, or use the EQTabs Add-in.
Follow us on Twitter @IHSEViews

KatellL
Posts: 6
Joined: Fri Feb 04, 2011 7:54 am

Re: Equations in a Model

Postby KatellL » Mon Jul 02, 2012 9:23 am

I think we might need to spool. The eqstacktab is close to what we're looking for, but it doesn't contain the information like the Durbin-Watson or the R-squared statistics.

Can you please explain how to spool. I looked in the command reference but I don't understand how to do it or what it does exactly.

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 12291
Joined: Tue Sep 16, 2008 5:38 pm

Re: Equations in a Model

Postby EViews Gareth » Mon Jul 02, 2012 9:42 am

Code: Select all

spool myspool
myspool.append eq1
myspool.append eq2
.....


or, if you just want to spool every equation in the workfile:

Code: Select all

%eqnames = @wlookup("*", "equation")
spool myspool
for !i=1 to @wcount(%eqnames)
   %name = @word(%eqnames, !i)
   myspool.append {%name}
next
Follow us on Twitter @IHSEViews

KatellL
Posts: 6
Joined: Fri Feb 04, 2011 7:54 am

Re: Equations in a Model

Postby KatellL » Mon Jul 02, 2012 10:27 am

When I do a few with the first code, it's exactly what I was looking for.

Since I have 100 equations, I would prefer to use the second code. But, the third line in the code gives the error "Flow of control statement executed from the command line." When I click OK and try to run the next line, I get the error "!I is not defined."

Am I missing an add-in or something?

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 12291
Joined: Tue Sep 16, 2008 5:38 pm

Re: Equations in a Model

Postby EViews Gareth » Mon Jul 02, 2012 10:35 am

You need to run it from a program, not the command window.
Follow us on Twitter @IHSEViews

KatellL
Posts: 6
Joined: Fri Feb 04, 2011 7:54 am

Re: Equations in a Model

Postby KatellL » Mon Jul 02, 2012 10:48 am

Thank you!


Return to “Models”

Who is online

Users browsing this forum: No registered users and 1 guest