Forecast using bayesian estimation

This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location where you will have to reset your password.
Forum rules
This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location (https://forum.dynare.org) where you will have to reset your password.

Forecast using bayesian estimation

Postby wgonzalez » Tue May 29, 2007 1:20 am

I am trying to reply the Smets and Wouter (2003) work , in which I want to make forecast for the euro zone but I have an error when trying to carry out it, I would thank them enough if could tell me how can I solve that problem. The error finishing the algorithm metropolis - hastings is

?? Error using ==> plus
Matrix dimensions must agree.

Error in ==> <a href="error:C:\dynare_v3\matlab\metropolis.m,2039,1">metropolis at 2039</a>
yf(:,IdObs) = yf(:,IdObs)+repmat(bayestopt_.mean_varobs', ...

Error in ==> <a href="error:C:\dynare_v3\matlab\dynare_estimation.m,778,1">dynare_estimation at 778</a>
metropolis(xparam1,invhess,gend,data,rawdata,bounds);

Error in ==> <a href="error:C:\Documents and Settings\Administrador\Escritorio\sw\sw6.m,277,1">sw6 at 277</a>
dynare_estimation(var_list_);

Error in ==> <a href="error:C:\dynare_v3\matlab\dynare.m,26,1">dynare at 26</a>
evalin('base',fname) ;


thanks in advance

WGonzalez
wgonzalez
 
Posts: 13
Joined: Sat Mar 11, 2006 2:29 pm

Postby jtsoukalas » Tue Apr 22, 2008 8:27 pm

Dear WGonzalez

I think you are estimating with prefilter option == 1.


Simply remove the transpose from bayestopt_.mean_varobs' in this and several lines down in the metropolis.m file. I think it should work.

JT

Error in ==> <a href="error:C:\dynare_v3\matlab\metropolis.m,2039,1">metropolis at 2039</a>
yf(:,IdObs) = yf(:,IdObs)+repmat(bayestopt_.mean_varobs'
John D. Tsoukalas
University of Nottingham
jtsoukalas
 
Posts: 11
Joined: Mon Mar 27, 2006 9:23 am


Return to Dynare help

Who is online

Users browsing this forum: Google [Bot] and 8 guests