[Highfrequency-commits] r35 - pkg/highfrequency/R

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Wed Aug 15 02:41:18 CEST 2012


Author: jonathan
Date: 2012-08-15 02:41:18 +0200 (Wed, 15 Aug 2012)
New Revision: 35

Modified:
   pkg/highfrequency/R/realized.R
Log:
Solving the problem of exploding variances in heavyModel function

Modified: pkg/highfrequency/R/realized.R
===================================================================
--- pkg/highfrequency/R/realized.R	2012-08-14 02:13:07 UTC (rev 34)
+++ pkg/highfrequency/R/realized.R	2012-08-15 00:41:18 UTC (rev 35)
@@ -4114,6 +4114,7 @@
       }
     }#End loop over innovation lags
     
+    if( any( h[,t]>1e3 )){ break ;}
     # Check whether h's are between LB and UB:      
     for(j in 1:K){ #Loop over 
       if( h[j,t] < LB[j] ){  h[j,t] = LB[j]/(1- (h[j,t] - LB[j]) );}
@@ -4135,5 +4136,4 @@
     # (ii) likelihood parts per time period
     # (iii) matrix with conditional variances    
   } #end output in case you want params
-}    
-
+}



More information about the Highfrequency-commits mailing list