Extracting Equation from Eviews to Excel

For questions regarding the import, export and manipulation of data in EViews, including graphing and basic statistics.

Moderators: EViews Gareth, EViews Jason, EViews Steve, EViews Moderator

jiangsujie
Posts: 2
Joined: Thu Feb 11, 2010 5:00 am

Extracting Equation from Eviews to Excel

Postby jiangsujie » Thu Feb 11, 2010 5:32 am

Hello,

Eviews 7 has an excel plug-in that allows users to extract data from EViews workfiles. But i've found that the Excel plug-in can extract only series or Vectors, not equations or groups, does anyone know how to use Eviews plug-in in excel to extract them?

Thanks!

sujie

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

Re: Extracting Equation from Eviews to Excel

Postby EViews Gareth » Thu Feb 11, 2010 8:56 am

I'm not sure your question really makes much sense. Excel doesn't have an equivalent of an Equation object. How would EViews send it across?
Follow us on Twitter @IHSEViews

EViews Steve
EViews Developer
Posts: 799
Joined: Tue Sep 16, 2008 3:00 pm
Location: Irvine, CA

Re: Extracting Equation from Eviews to Excel

Postby EViews Steve » Thu Feb 11, 2010 10:57 am

The EViews Excel Add In was meant to be a helpful utility in allowing users to access EViews data directly thru the new OLEDB driver. It is limited to those objects that can be read by the OLEDB driver.

Unfortunately, at this time, the OLEDB driver does not support reading group or equation objects. Support for reading groups may be added in near future.

Steve

jiangsujie
Posts: 2
Joined: Thu Feb 11, 2010 5:00 am

Re: Extracting Equation from Eviews to Excel

Postby jiangsujie » Fri Feb 12, 2010 5:53 am

What i mean is that if Eviews equation estimations are updated regularly, it's a bit troublesome to copy and paste the parameters into excel manually, so the ability to access Eviews equations from Excel would be very helpful.

For now, do you have a solution for extracting equation parameters for a group of equations?

Thanks again!


QMS Gareth wrote:I'm not sure your question really makes much sense. Excel doesn't have an equivalent of an Equation object. How would EViews send it across?

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

Re: Extracting Equation from Eviews to Excel

Postby startz » Fri Feb 12, 2010 7:39 am

Generally, the parameters are stored in the C vector. Can you send that across?

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

Re: Extracting Equation from Eviews to Excel

Postby EViews Gareth » Fri Feb 12, 2010 9:03 am

Startz is right. An Equation object could not be passed from EViews to another package, such as Excel, since Equations are somewhat unique to EViews. However, you can always pass the results of an Equation over to Excel, since you can generally put the results into Vector or Matrix objects, then pass those over.
Follow us on Twitter @IHSEViews

amina
Posts: 3
Joined: Mon May 10, 2010 8:06 pm

Re: Extracting Equation from Eviews to Excel

Postby amina » Mon May 10, 2010 9:04 pm

EViews Gareth wrote:Startz is right. An Equation object could not be passed from EViews to another package, such as Excel, since Equations are somewhat unique to EViews. However, you can always pass the results of an Equation over to Excel, since you can generally put the results into Vector or Matrix objects, then pass those over.


Hello Gareth! Could you please explain how to put the results from an equation into a Vector or Matrix? Thanks in advance!

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

Re: Extracting Equation from Eviews to Excel

Postby EViews Gareth » Mon May 10, 2010 9:31 pm

Code: Select all

matrix coefs = eq1.@coefs
matrix cov = eq1.@coefcov


Where eq1 is the name of your equation. The other data members can be found in the equation section of the Object Reference.
Follow us on Twitter @IHSEViews

amina
Posts: 3
Joined: Mon May 10, 2010 8:06 pm

Re: Extracting Equation from Eviews to Excel

Postby amina » Tue May 11, 2010 4:38 am

EViews Gareth wrote:

Code: Select all

matrix coefs = eq1.@coefs
matrix cov = eq1.@coefcov


Where eq1 is the name of your equation. The other data members can be found in the equation section of the Object Reference.


Thanks for your fast reply Gareth!
I'm automating a regression evaluation by using Eviews from Visual Basic.Net. I'm able to send data to series, and executing an equation with the following command:
app.Run("LS LOG(MWH) @TREND H1 H2 H3 H4 H5 H6 H7 C ")

Do you know how to retrieve the coefficients returned by the equation, with VBnet?
Thank you very much!

EViews Steve
EViews Developer
Posts: 799
Joined: Tue Sep 16, 2008 3:00 pm
Location: Irvine, CA

Re: Extracting Equation from Eviews to Excel

Postby EViews Steve » Tue May 11, 2010 8:07 am

Make a small change to your Run command to actually create an equation object like this:

Code: Select all

app.Run("EQUATION EQ1.LS LOG(MWH) @TREND H1 H2 H3 H4 H5 H6 H7 C")

Then, to retrieve the parts, you don't actually have to create separate vectors/matrices. Just run:

Code: Select all

app.Get("=EQ1.@coefs")

or

Code: Select all

app.Get("=EQ1.@coefcov")


Steve

amina
Posts: 3
Joined: Mon May 10, 2010 8:06 pm

Re: Extracting Equation from Eviews to Excel

Postby amina » Tue May 11, 2010 8:10 am

Thank you very much Steve! I appreciate your help

CharlesLogan
Posts: 12
Joined: Fri Dec 17, 2010 3:31 pm

Re: Extracting Equation from Eviews to Excel

Postby CharlesLogan » Fri Dec 17, 2010 3:46 pm

It would be very handy for Eviews to have the ability to export to Excel the Substituted Coefficient representation of an Equation as a STRING.

EViews Glenn
EViews Developer
Posts: 2672
Joined: Wed Oct 15, 2008 9:17 am

Re: Extracting Equation from Eviews to Excel

Postby EViews Glenn » Fri Dec 17, 2010 4:24 pm

It is. See the @subst data member of an equation. Put it in a table, and save to disk as a .csv which can be read by Excel.

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

Extracting Equation from Eviews to Excel

Postby EViews Gareth » Fri Dec 17, 2010 4:39 pm

Or use COM to send the string across to Excel
Follow us on Twitter @IHSEViews

vkarora
Posts: 9
Joined: Fri May 31, 2013 10:59 am

Re: Extracting Equation from Eviews to Excel

Postby vkarora » Fri May 31, 2013 11:02 am

"It is. See the @subst data member of an equation. Put it in a table, and save to disk as a .csv which can be read by Excel."

Is there anything similar for use with the one or more equations of a VAR object? Or possibly a workaround if such a command does not exist?

Thanks


Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 31 guests