Suppressing Error message division by 0

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

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

DBel2012
Posts: 69
Joined: Sun Sep 30, 2012 5:37 am

Suppressing Error message division by 0

Postby DBel2012 » Mon Sep 23, 2013 5:51 am

Hello,

I'm using Eviews 7.

I've got a program that creates new time series from a group, based on the annual percentage change (ex. var_A=@pchy(var_B)).

Since series from that group can be equal to 0 in the sample period, an error message is generated by Eviews and it stops processing the series in that group.

Is it possible to tell Eviews either not to generate an error message when a division by zero occures, or generate the error message but continue processing with the remaining series of the group?

Thanks!

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

Re: Suppressing Error message division by 0

Postby EViews Gareth » Mon Sep 23, 2013 7:52 am

When you run the program, set the maximum number of errors to something high.

DBel2012
Posts: 69
Joined: Sun Sep 30, 2012 5:37 am

Re: Suppressing Error message division by 0

Postby DBel2012 » Mon Sep 23, 2013 8:19 am

Many thanks Gareth!

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

Re: Suppressing Error message division by 0

Postby jthodge » Tue Oct 08, 2013 1:05 pm

I think this would work also (assuming you have a monthly workfile):

Code: Select all

smpl @all if var_B(-12)<>0 genr var_A=@pchy(var_B) smpl @all


Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 2 guests