Sounds like a coding error.
Maybe. I am mostly adapting existing codes for my own needs, but it is strange.I am running 2-step DCC Garch regressions using one of the add-ins and it works fine for say 5-10 stocks (I started with 3 stocks and then increased it to 5 and then 10; all is estimated fine). So, I thought the loop works and everything. However, once I increased the code to 50 stocks both runs it stopped on the correlation 307 or 308 or in about 15 minutes. It also works if I restart the loop from say a pair combination number 290. It just go through the 307th or 308th pair of stocks just fine until it breaks again in 15 minutes time or on the next 600th correlation or so.
Now I've tried it on my home PC. I've got "!TODAY is not defined" message on stocks pair number 126, after around 6 minutes. Can it be because I am using EViews via Jukebox, an app that my Uni supplies so everyone has a remote access to all programs purchased by the Uni? Also I have a Mac at home and I am using Parallels Desktop for Windows, while at Uni it is Windows 10 PC. Here is the code I am using (the data attached):
Code: Select all
'create empty equation to be used inside the loop
equation eq
'counter of how many equations we have run
!rowcounter=1
'run pairwise regressions between each series
for !i=1 to 50
!rowcounter = !i
for !j=1 to 50
if !i<>!j then
equation eq{!i}.ls x{!i} c ar(1)
eq{!i}.makeresid x{!i}r
endif
next
next
'company 1
for !i=2 to 50
!rowcounter = !i
' for !j=2 to 50
if !i<>!j then
group g1{!i} x1r x{!i}r
g1{!i}.dccgarch11(unifit="GARCH",ctarget,correl,dccout,unigarch)
endif
next
'next
'company 2
for !i=3 to 50
!rowcounter = !i
' for !j=3 to 50
if !i<>!j then
group g2{!i} x2r x{!i}r
g2{!i}.dccgarch11(unifit="GARCH",ctarget,correl,dccout,unigarch)
endif
next
'next
'company 3
for !i=4 to 50
!rowcounter = !i
' for !j=4 to 50
if !i<>!j then
group g3{!i} x3r x{!i}r
g3{!i}.dccgarch11(unifit="GARCH",ctarget,correl,dccout,unigarch)
endif
next
'next
'company 4
for !i=5 to 50
!rowcounter = !i
' for !j=5 to 50
if !i<>!j then
group g4{!i} x4r x{!i}r
g4{!i}.dccgarch11(unifit="GARCH",ctarget,correl,dccout,unigarch)
endif
next