Log of non positive number

For questions regarding programming in the EViews programming language.

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

GilMan
Posts: 2
Joined: Tue Nov 02, 2010 6:36 am

Log of non positive number

Postby GilMan » Thu Nov 04, 2010 5:50 pm

Hi, i'm trying to run this code below,

but the following error appears "Log of non positive number"

code

for !i=1 to group01.@count

%iname = group01.@seriesname(!i)
!icode = 1
!j = 1


for !i=1 to group01.@count

equation calculategarch{!icode}.arch(ged) {%iname} c
calculategarch{!icode}.makegarch {%iname} + !j

group calculatedgarch
calculatedgarch.add {%iname} + !j

!icode = !icode + 1
!j = !j + 1
next
next

Can someone help me please!!

I'm using ev 5.1

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

Re: Log of non positive number

Postby EViews Gareth » Thu Nov 04, 2010 6:26 pm

That's a crazy looking loop you have there, it seems you're running two loops, one inside the other, using !i for both.

However I don't think that is causing the error. The most likely cause is that one of the ARCH estimations is going wrong. Nobody is going to be able to help much more than that without running it on the data themselves.


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 1 guest