Series transformation problem

For notifying us of what you believe are bugs or errors in EViews.
Please ensure your copy of EViews is up-to-date before posting.

Moderators: EViews Gareth, EViews Moderator

Posts: 77
Joined: Tue Oct 21, 2008 5:52 am

Series transformation problem

Postby jthodge » Wed Mar 24, 2010 1:56 pm

We recently uncovered an error in our Eviews code that might point to a possible bug in both Eviews 6 and 7. Our program reads in and manipulates population data, with series names such as POPTX (population in Texas).

After reading in the data, one of the lines in our code scales the variable using the following command:

You'll notice that the right-hand-side series name (incorrectly) includes an underscore ("_") whereas the original (correct) series name did not. However, for some reason Eviews allows this new series to be created from a non-existent series (the new series POP_TX is full of N/As).

In comparison, if we were to try generating a new series from a non-existent series that does not have an underscore in its name, e.g.,
we do receive an error message saying "POPTEST is not defined."

So, why the difference? Is "POP_" a reserved name in Eviews or is this some sort of bug?

Posts: 77
Joined: Tue Oct 21, 2008 5:52 am

Re: Series transformation problem

Postby jthodge » Wed Mar 24, 2010 2:07 pm


I think the issue is that the left-hand-side and right-hand-side variables are the same.

Say you have a blank workfile. The following command will not generate an error:
(even though POPTEST did not exist prior to this command).

However, the following command will generate an error saying "POPTEST2 is not defined":

Shouldn't both cases generate a "not defined" error?

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

Re: Series transformation problem

Postby EViews Gareth » Wed Mar 24, 2010 2:27 pm

Indeed, the "_" issue was a red herring.

The issue is this... With the line:

You're basically saying to EViews "Create a series called POPTEST. Now set that series equal to the expression POPTEST/1000." EViews can do that no problem at all. First it creates a new, empty series (populated with NAs), then it sets that series equal to the expression POPTEST/1000. Of course at this point POPTEST does exist, but it is full of NAs, so the result is full of NAs with no error given.

When you do:

The same sequence happens - first POPTEST is created and full of NAs, then it is evaluated at POPTEST2/1000, but there is no series called POPTEST2, thus an error occurs.

This isn't really a bug. Just a quirk of the way that EViews (and many other languages) works.
Follow us on Twitter @IHSEViews

Return to “Bug Reports”

Who is online

Users browsing this forum: No registered users and 4 guests