v4: further corrections
git-svn-id: https://www.dynare.org/svn/dynare/dynare_v4@678 ac1d8469-bf42-47a9-8791-bf33cf982152time-shift
parent
e72a1d579c
commit
a8e01d23bf
|
@ -1,4 +1,4 @@
|
|||
function [alphahat,etahat,a1, aK, a] = DiffuseKalmanSmoother3(T,R,Q,Pinf1,Pstar1,Y,trend,pp,mm,smpl,mf)
|
||||
function [alphahat,etahat,a1, aK] = DiffuseKalmanSmoother3(T,R,Q,Pinf1,Pstar1,Y,trend,pp,mm,smpl,mf)
|
||||
%function [a,etahat,a1, aK] = DiffuseKalmanSmoother3(T,R,Q,Pinf1,Pstar1,Y,trend,pp,mm,smpl,mf)
|
||||
% Modified by M. Ratto
|
||||
% New output argument aK: 1-step to nk-stpe ahed predictions)
|
||||
|
@ -20,7 +20,7 @@ function [alphahat,etahat,a1, aK, a] = DiffuseKalmanSmoother3(T,R,Q,Pinf1,Pstar1
|
|||
|
||||
global options_
|
||||
|
||||
nk = options_.nk;
|
||||
nk = options_.nk;
|
||||
spinf = size(Pinf1);
|
||||
spstar = size(Pstar1);
|
||||
v = zeros(pp,smpl);
|
||||
|
@ -102,9 +102,9 @@ while newRank & t < smpl
|
|||
options_.diffuse_d = icc;
|
||||
end
|
||||
end,
|
||||
% if newRank==0,
|
||||
% options_.diffuse_d=i; %this is buggy
|
||||
% end
|
||||
% if newRank==0,
|
||||
% options_.diffuse_d=i; %this is buggy
|
||||
% end
|
||||
% end new terminiation criteria by M. Ratto
|
||||
else
|
||||
%% Note that : (1) rank(Pinf)=0 implies that Finf = 0, (2) outside this loop (when for some i and t the condition
|
||||
|
|
|
@ -82,7 +82,7 @@ function [alphahat,etahat,epsilonhat,ahat,SteadyState,trend_coeff,aK] = DsgeSmoo
|
|||
if options_.kalman_algo == 1
|
||||
[alphahat,etahat,ahat,aK] = DiffuseKalmanSmoother1(T,R,Q,Pinf,Pstar,Y,trend,nobs,np,smpl,mf);
|
||||
if all(alphahat(:)==0)
|
||||
[alphahat,etahat,ahat] = DiffuseKalmanSmoother3(T,R,Q,Pinf,Pstar,Y,trend,nobs,np,smpl,mf);
|
||||
[alphahat,etahat,ahat,aK] = DiffuseKalmanSmoother3(T,R,Q,Pinf,Pstar,Y,trend,nobs,np,smpl,mf);
|
||||
end
|
||||
elseif options_.kalman_algo == 3
|
||||
[alphahat,etahat,ahat,aK] = DiffuseKalmanSmoother3(T,R,Q,Pinf,Pstar,Y,trend,nobs,np,smpl,mf);
|
||||
|
|
Loading…
Reference in New Issue