Page 1 of 1

Multiplying Na by zero

Posted: Mon Jul 23, 2018 7:43 am
by mvictor96
Hello

I'm performing an operation where I need NA*0 to equal 0 instead of NA . I've read in eviews 2 this used to be the default. In Eviews 10 do you know of any ways I could make this still work

Thank you

Re: Multiplying Na by zero

Posted: Mon Jul 23, 2018 7:48 am
by startz
One way

Code: Select all

series newVar = @recode(oldvar1=na,0,oldvar1)*@recode(oldvar2=na,0,oldvar2)
or something like that, although that would also give NA*7 = 0 which may not be what you want.

Re: Multiplying Na by zero

Posted: Mon Jul 23, 2018 8:17 am
by mvictor96
Thanks for your help but yes at the moment I need solely 0*NA to equal 0