@recode not working properly

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

mamo
Posts: 205
Joined: Wed Nov 07, 2012 9:11 am

@recode not working properly

Postby mamo » Fri Nov 22, 2019 3:13 am

Dear Eviewers,
I use Eviews 11 build Sept 2019
@recode does not work properly in assignments, see code below which breaks due to log of non-negative number
(Same @recode command as in context of "show" works, however)

Code: Select all

wfcreate a 2000 2010 series x=nrnd show @recode(x<=0,NA,log(x)) 'this works series y=@recode(x<=0,NA,log(x)) 'this doesn't, but it should work as well as the line above

mamo
Posts: 205
Joined: Wed Nov 07, 2012 9:11 am

Re: @recode not working properly

Postby mamo » Fri Nov 22, 2019 3:50 am

I have found a work-around

Code: Select all

wfcreate a 2000 2010 series x=nrnd ' show @recode(x<=0,NA,log(x)) 'this works series y=0 'pre-define y series y=@recode(x<=0,y,log(x)) 'this works as well!!
Best, mamo

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

Re: @recode not working properly

Postby EViews Gareth » Fri Nov 22, 2019 8:19 am

Not really a bug - EViews is supposed to error/warn when you create a series that generates NAs. The series is still created.


Return to “Bug Reports”

Who is online

Users browsing this forum: No registered users and 2 guests