Error: "NA found in matrix in"

For questions regarding programming in the EViews programming language.

Moderators: EViews Gareth, EViews Jason, EViews Moderator, EViews Matt

Lama
Posts: 15
Joined: Tue Oct 28, 2008 12:07 am

Error: "NA found in matrix in"

Postby Lama » Thu May 07, 2009 12:00 pm

Dear all,

in my program I get the error ""NA found in matrix in" while trying to execute a for-loop (combined with "if-then-else").

Now I'm stuck: I do not even use a matrix in these operations (just plain series) and I do not understand why NA could be a problem.

I checked, in the series that is tested with an if-then command there are some NA but there are "valid" values, too.

I'd be very grateful if somebody could help me

Yours,

Lama

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

Re: Error: "NA found in matrix in"

Postby EViews Gareth » Thu May 07, 2009 12:10 pm

We'll need more information.

The ideal situation would be for you to post the workfile and the program...
Follow us on Twitter @IHSEViews

Lama
Posts: 15
Joined: Tue Oct 28, 2008 12:07 am

Re: Error: "NA found in matrix in"

Postby Lama » Thu May 07, 2009 11:29 pm

Hi Gareth,

of course you're right.

(The program should result in a season's overall score.)

eviews1.prg
(769 Bytes) Downloaded 571 times
Eviewswkfile1.WF1
(28.95 KiB) Downloaded 441 times



Thanx a lot!

Lama

trubador
Did you use forum search?
Posts: 1518
Joined: Thu Nov 20, 2008 12:04 pm

Re: Error: "NA found in matrix in"

Postby trubador » Fri May 08, 2009 4:50 am

It seems, as a first impression, your specification of IF statement is incorrect. You should check the following link for an example similar to your case: http://forums.eviews.com/viewtopic.php?f=5&t=799#p2679 Other than that, what you are trying to achieve is still somewhat ambiguous. If possible, please give some more information on the variables and definiton of your problem...

Lama
Posts: 15
Joined: Tue Oct 28, 2008 12:07 am

Re: Error: "NA found in matrix in"

Postby Lama » Sat May 09, 2009 5:26 am

Hi Trubador,

thanks a lot for your hint.

The problem now is fixed: I just forgot to tell EVIEWS which particular element in the series had to be increased. Now the error does not occur anymore.

Sorry for bothering you & thanks again

Lama


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 38 guests