diff --git a/matlab/+occbin/IVF_posterior.m b/matlab/+occbin/IVF_posterior.m
index 2783e2b1c492e80aea94bc6c63da10958ba988df..db4d51ec06fd178c9e4620e5e079814266042795 100644
--- a/matlab/+occbin/IVF_posterior.m
+++ b/matlab/+occbin/IVF_posterior.m
@@ -113,7 +113,6 @@ else
     atT = stateval(:,DynareResults.dr.order_var)';
     innov = zeros(Model.exo_nbr,sample_length);
     innov(diag(Model.Sigma_e)~=0,:)=filtered_errs';
-    updated_variables = atT*nan;
 end
 nobs=size(filtered_errs,1);
 
@@ -191,12 +190,4 @@ end
 
 % remember that the likelihood has already been multiplied by -1
 % hence, posterior is -1 times the log of the prior
-fval = like+prior;
-
-BayesInfo.mf = BayesInfo.smoother_var_list(BayesInfo.smoother_mf);
-
-
-initDynareOptions=DynareOptions;
-DynareOptions.nk=[]; %unset options_.nk and reset it later
-[DynareResults]=store_smoother_results(Model,DynareResults,DynareOptions,BayesInfo,dataset_,obs_info,atT,innov,[],updated_variables,DynareResults.dr.ys,zeros(length(DynareOptions.varobs_id),1));
-DynareOptions=initDynareOptions;
+fval = like+prior;
\ No newline at end of file