Hello,
After a successful estimation using Occbin, Dynare proceeded to run the smoother for a subsample of my endogenous variables (I asked for three of my 34 endogenous vars). However, the process faied with the following message:
Unable to perform assignment because the size of the left side is 0-by-17-by-0 and the size of the right side is 1-by-17-by-2.
Error in DsgeSmoother (line 455)
aaa(:,oo_.dr.restrict_var_list,:)=aK;
Error in occbin.DSGE_smoother (line 120)
[alphahat,etahat,epsilonhat,ahat,SteadyState,trend_coeff,aK,T0,R0,P,PK,decomp,Trend,state_uncertainty,M_,oo_,bayestopt_] = DsgeSmoother(xparam1,gend,Y,data_index,missing_value,M_,oo_,options_,bayestopt_,estim_params_,occbin_options);%
T1=TT;
Error in dynare_estimation_1 (line 599)
[atT,innov,measurement_error,updated_variables,ys,trend_coeff,aK,T,R,P,PK,decomp,Trend,state_uncertainty,M_,oo_,bayestopt_] =
occbin.DSGE_smoother(xparam1,dataset_.nobs,transpose(dataset_.data),dataset_info.missing.aindex,dataset_info.missing.state,M_,oo_,options_,bayestopt_,estim_params_,dataset_,dataset_info);
Is there an obvious reason why this might occur? I can provide files for replication, but unfortunately the estimation takes roughly 4 weeks to run, making it difficult to replicate from scratch.
UPDATE: Part of the issue is that āoptions_.nkā is unset and is empty, for some reason. Manually setting options_.nk = 1 before running the smoother helps. However, there is still an error because the dimensions of aK are completely wrong - aK is of size (1, 17, 2), when it is expected to be (1, 17, 69) (as I have 68 observations).
UPDATE 2: setting nk>1 fixes the problem. For example, setting nk=2 leads to aK have the dimensions 2 17 70. This seems to be caused by line 436 in āmissing_DiffuseKalmanSmootherH3_Z.mā, which generates Occbin output only if nk> 1 (and otherwise does not invoke Occbin correctly).