diff --git a/matlab/missing_DiffuseKalmanSmootherH1_Z.m b/matlab/missing_DiffuseKalmanSmootherH1_Z.m index ff8c99a0b103fc95693fbbab93229b7d0b49f436..4b501477129347051923fd752f35d45eecc9b75a 100644 --- a/matlab/missing_DiffuseKalmanSmootherH1_Z.m +++ b/matlab/missing_DiffuseKalmanSmootherH1_Z.m @@ -177,7 +177,7 @@ while notsteady && t<smpl atilde(:,t) = a(:,t) + PZI*v(di,t); K(:,di,t) = T*PZI; L(:,:,t) = T-K(:,di,t)*ZZ; - P(:,:,t+1) = T*P(:,:,t)*T'-T*P(:,:,t)*ZZ'*K(:,di,t)' + QQ; + P(:,:,t+1) = T*P(:,:,t)*L(:,:,t)' + QQ; end a(:,t+1) = T*atilde(:,t); Pf = P(:,:,t);